UNPKG

1.09 kBMarkdownView Raw
1This directory contains runnable sample mongoose programs.
2
3To run:
4
5 - first install [Node.js](http://nodejs.org/)
6 - from the root of the project, execute `npm install -d`
7 - in the example directory, run `npm install -d`
8 - from the command line, execute: `node example.js`, replacing "example.js" with the name of a program.
9
10
11Goal is to show:
12
13- ~~global schemas~~
14- ~~GeoJSON schemas / use (with crs)~~
15- text search (once MongoDB removes the "Experimental/beta" label)
16- ~~lean queries~~
17- ~~statics~~
18- methods and statics on subdocs
19- custom types
20- ~~querybuilder~~
21- ~~promises~~
22- accessing driver collection, db
23- ~~connecting to replica sets~~
24- connecting to sharded clusters
25- enabling a fail fast mode
26- on the fly schemas
27- storing files
28- ~~map reduce~~
29- ~~aggregation~~
30- advanced hooks
31- using $elemMatch to return a subset of an array
32- query casting
33- upserts
34- pagination
35- express + mongoose session handling
36- ~~group by (use aggregation)~~
37- authentication
38- schema migration techniques
39- converting documents to plain objects (show transforms)
40- how to $unset
41