Create & Find GeoLocation in mongoose
问题 I'm trying to save the longitude/latitude of a location in my user Model and query it with $geoNear . I've looked at almost any page I could find on that topic, but still I'm not sure how to 1) create the model appropriately and how to query it. here's the part of my model: loc: { //type: 'Point', // see 1 //type: String, // see 2 coordinates: [Number], index: '2dsphere' // see 3 }, @1: According the documentation the type must be 'Point' if I want to store a point, but it throws TypeError: