August 2013
Intermediate to advanced
142 pages
2h 42m
English
There are eight types of data that can—by default—be set in a Mongoose schema. These are also referred to as SchemaTypes; they are:
The first four SchemaTypes are self-explanatory, but let's take a quick look at them all.
This SchemaType stores a string value, UTF-8 encoded.
This SchemaType stores a number value, with restrictions. Mongoose does not natively support long and double datatypes for example, although MongoDB does. However, Mongoose can be extended using plugins to support these other types. See Chapter 11, Plugins – Re-using Code for more on plugins.
This SchemaType holds a date and time object, typically returned from MongoDB as an ISODate object, ...
Read now
Unlock full access