{"id":18523598,"url":"https://github.com/mongoosejs/mongoose-v2-compat","last_synced_at":"2025-07-29T05:05:25.827Z","repository":{"id":3448104,"uuid":"4501281","full_name":"mongoosejs/mongoose-v2-compat","owner":"mongoosejs","description":"Adds a compatibility layer to Mongoose v3 to regain most of the API sugar from Mongoose v2","archived":false,"fork":false,"pushed_at":"2012-06-20T19:25:54.000Z","size":104,"stargazers_count":1,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-06-25T08:15:42.844Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"JavaScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/mongoosejs.png","metadata":{"files":{"readme":"README.md","changelog":"History.md","contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2012-05-30T22:17:55.000Z","updated_at":"2016-10-12T02:18:48.000Z","dependencies_parsed_at":"2022-09-26T17:01:12.696Z","dependency_job_id":null,"html_url":"https://github.com/mongoosejs/mongoose-v2-compat","commit_stats":null,"previous_names":["aheckmann/mongoose-v2-compat"],"tags_count":2,"template":false,"template_full_name":null,"purl":"pkg:github/mongoosejs/mongoose-v2-compat","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mongoosejs%2Fmongoose-v2-compat","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mongoosejs%2Fmongoose-v2-compat/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mongoosejs%2Fmongoose-v2-compat/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mongoosejs%2Fmongoose-v2-compat/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/mongoosejs","download_url":"https://codeload.github.com/mongoosejs/mongoose-v2-compat/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mongoosejs%2Fmongoose-v2-compat/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":267037585,"owners_count":24025606,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","status":"online","status_checked_at":"2025-07-25T02:00:09.625Z","response_time":70,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-11-06T17:36:26.265Z","updated_at":"2025-07-29T05:05:25.773Z","avatar_url":"https://github.com/mongoosejs.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"#mongoose-v2-compat\n====================\n\nAdds a compatibility layer to Mongoose v3 to regain most of the API sugar from Mongoose v2.\n\n## install\n\n```\nnpm install mongoose-v2-compat\n```\n\nExample:\n\n```js\nrequire('mongoose-v2-compat');\nvar mongoose = require('mongoose');\nmongoose.compat = true;\n\n// now we can use all the old methods\nmongoose.connectSet('...');\n\nThing.where('tags').$in(array).asc('name').run(callback);\n```\n\n## Provided methods\n\n  - Query#$or\n  - Query#$nor\n  - Query#$gt\n  - Query#$gte\n  - Query#$lt\n  - Query#$lte\n  - Query#$ne\n  - Query#$in\n  - Query#$nin\n  - Query#$all\n  - Query#$regex\n  - Query#$size\n  - Query#$maxDistance\n  - Query#$mod\n  - Query#$near\n  - Query#$exists\n  - Query#$elemMatch\n  - Query#$within\n  - Query#$box\n  - Query#$center\n  - Query#$centerSphere\n  - Query#$slice\n  - Query#run\n  - Query#notEqualTo\n  - Query#wherein\n  - Query#fields\n  - Query#asc\n  - Query#desc\n  - mongoose.createSetConnection\n  - mongoose.connectSet\n  - document#commit\n  - MongooseArray#$push\n  - MongooseArray#$pushAll\n  - MongooseArray#$pull\n  - MongooseArray#$pullAll\n  - MongooseArray#$unshift\n  - MongooseArray#$addToSet\n\n## tests\n\nRun the tests with `make test`.\n\n[LICENSE](https://github.com/aheckmann/mongoose-v2-compat/blob/master/LICENSE)\n\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmongoosejs%2Fmongoose-v2-compat","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fmongoosejs%2Fmongoose-v2-compat","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmongoosejs%2Fmongoose-v2-compat/lists"}