├── .gitignore ├── .npmignore ├── LICENSE ├── README.md ├── package.json ├── src ├── crud-mongoose.service.ts └── index.ts ├── tsconfig.json └── yarn.lock /.gitignore: -------------------------------------------------------------------------------- 1 | # Logs 2 | logs 3 | *.log 4 | npm-debug.log* 5 | yarn-debug.log* 6 | yarn-error.log* 7 | 8 | # Runtime data 9 | pids 10 | *.pid 11 | *.seed 12 | *.pid.lock 13 | 14 | # Directory for instrumented libs generated by jscoverage/JSCover 15 | lib-cov 16 | 17 | # Coverage directory used by tools like istanbul 18 | coverage 19 | 20 | # nyc test coverage 21 | .nyc_output 22 | 23 | # Grunt intermediate storage (http://gruntjs.com/creating-plugins#storing-task-files) 24 | .grunt 25 | 26 | # Bower dependency directory (https://bower.io/) 27 | bower_components 28 | 29 | # node-waf configuration 30 | .lock-wscript 31 | 32 | # Compiled binary addons (https://nodejs.org/api/addons.html) 33 | build/Release 34 | 35 | # Dependency directories 36 | node_modules/ 37 | jspm_packages/ 38 | 39 | # TypeScript v1 declaration files 40 | typings/ 41 | 42 | # Optional npm cache directory 43 | .npm 44 | 45 | # Optional eslint cache 46 | .eslintcache 47 | 48 | # Optional REPL history 49 | .node_repl_history 50 | 51 | # Output of 'npm pack' 52 | *.tgz 53 | 54 | # Yarn Integrity file 55 | .yarn-integrity 56 | 57 | # dotenv environment variables file 58 | .env 59 | 60 | # next.js build output 61 | .next 62 | dist -------------------------------------------------------------------------------- /.npmignore: -------------------------------------------------------------------------------- 1 | # Logs 2 | logs 3 | *.log 4 | npm-debug.log* 5 | yarn-debug.log* 6 | yarn-error.log* 7 | 8 | # Runtime data 9 | pids 10 | *.pid 11 | *.seed 12 | *.pid.lock 13 | 14 | # Directory for instrumented libs generated by jscoverage/JSCover 15 | lib-cov 16 | 17 | # Coverage directory used by tools like istanbul 18 | coverage 19 | 20 | # nyc test coverage 21 | .nyc_output 22 | 23 | # Grunt intermediate storage (http://gruntjs.com/creating-plugins#storing-task-files) 24 | .grunt 25 | 26 | # Bower dependency directory (https://bower.io/) 27 | bower_components 28 | 29 | # node-waf configuration 30 | .lock-wscript 31 | 32 | # Compiled binary addons (https://nodejs.org/api/addons.html) 33 | build/Release 34 | 35 | # Dependency directories 36 | node_modules/ 37 | jspm_packages/ 38 | 39 | # TypeScript v1 declaration files 40 | typings/ 41 | 42 | # Optional npm cache directory 43 | .npm 44 | 45 | # Optional eslint cache 46 | .eslintcache 47 | 48 | # Optional REPL history 49 | .node_repl_history 50 | 51 | # Output of 'npm pack' 52 | *.tgz 53 | 54 | # Yarn Integrity file 55 | .yarn-integrity 56 | 57 | # dotenv environment variables file 58 | .env 59 | 60 | # next.js build output 61 | .next -------------------------------------------------------------------------------- /LICENSE: -------------------------------------------------------------------------------- 1 | MIT License 2 | 3 | Copyright (c) 2019 TopFullStack 4 | 5 | Permission is hereby granted, free of charge, to any person obtaining a copy 6 | of this software and associated documentation files (the "Software"), to deal 7 | in the Software without restriction, including without limitation the rights 8 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 9 | copies of the Software, and to permit persons to whom the Software is 10 | furnished to do so, subject to the following conditions: 11 | 12 | The above copyright notice and this permission notice shall be included in all 13 | copies or substantial portions of the Software. 14 | 15 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 16 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 17 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 18 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 19 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 20 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE 21 | SOFTWARE. 22 | -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | # nestjs-crud-mongoose 2 | Mongoose/Typegoose service adapter for [@nestjsx/crud](https://github.com/nestjsx/crud) 3 | 4 | > Nest.js + typegoose video (chinese): 5 | > 6 | > Nest.js + Typegoose 中文视频教程请移步哔哩哔哩全栈之巅: 7 | > 8 | > https://space.bilibili.com/341919508 9 | 10 | 11 | ## How to 12 | 13 | ### Install 14 | 15 | ```bash 16 | yarn add nestjs-crud-mongoose 17 | # or 18 | npm i nestjs-crud-mongoose 19 | ``` 20 | 21 | ### Create a service based on a mongoose/typegoose model 22 | `/src/users/users.service.ts` 23 | 24 | ```ts 25 | // for typegoose users 26 | import { User } from "../../common/users/user.model"; 27 | import { Injectable, Inject } from "@nestjs/common"; 28 | import { ModelType } from "@typegoose/typegoose/lib/types"; 29 | import { MongooseCrudService } from "./mongoose-crud.service"; 30 | 31 | @Injectable() 32 | export class UsersService extends MongooseCrudService{ 33 | constructor(@Inject('UserModel') public model: ModelType) { 34 | super(model) 35 | } 36 | } 37 | ``` 38 | 39 | OR 40 | 41 | ```ts 42 | // for mongoose users 43 | import { User } from "../../common/users/user.model"; 44 | import { Injectable, Inject } from "@nestjs/common"; 45 | import { Model } from "mongoose"; 46 | import { MongooseCrudService } from "./mongoose-crud.service"; 47 | 48 | @Injectable() 49 | export class UsersService extends MongooseCrudService{ 50 | constructor(@Inject('UserModel') public model: Model) { 51 | super(model) 52 | } 53 | } 54 | 55 | ``` 56 | 57 | ### Inject `UsersService` to your `UsersController`: 58 | 59 | ```ts 60 | @Crud({ 61 | // ... 62 | }) 63 | export class UsersController { 64 | constructor(public service: UsersService) { } 65 | } 66 | ``` 67 | 68 | 69 | ## Thanks to 70 | 71 | - https://github.com/nestjsx/crud 72 | - https://github.com/nestjsx/crud/tree/master/packages/crud-typeorm 73 | 74 | ## Related docs 75 | - https://github.com/nestjsx/crud/wiki/ServiceTypeorm -------------------------------------------------------------------------------- /package.json: -------------------------------------------------------------------------------- 1 | { 2 | "dependencies": { 3 | 4 | }, 5 | "name": "nestjs-crud-mongoose", 6 | "description": "Mongoose service adapter for @nestjsx/crud", 7 | "version": "1.1.1", 8 | "main": "dist/index.js", 9 | "typings": "dist/index.d.ts", 10 | "devDependencies": { 11 | "@nestjsx/crud": "^4.2.0", 12 | "@typegoose/typegoose": "^6.0.2", 13 | "@nestjs/common": "^6.7.2", 14 | "@types/mongoose": "^5.5.18", 15 | "rxjs": "^6.5.3", 16 | "tsc": "^1.20150623.0", 17 | "typescript": "^3.6.3" 18 | }, 19 | "scripts": { 20 | "build": "tsc", 21 | "test": "echo \"Error: no test specified\" && exit 1" 22 | }, 23 | "repository": { 24 | "type": "git", 25 | "url": "git+https://github.com/topfullstack/nestjs-crud-mongoose.git" 26 | }, 27 | "keywords": [ 28 | "mongoose", 29 | "crud", 30 | "nestjs" 31 | ], 32 | "author": "wu-xuesong@qq.com", 33 | "license": "MIT", 34 | "bugs": { 35 | "url": "https://github.com/topfullstack/nestjs-crud-mongoose/issues" 36 | }, 37 | "homepage": "https://github.com/topfullstack/nestjs-crud-mongoose#readme" 38 | } 39 | -------------------------------------------------------------------------------- /src/crud-mongoose.service.ts: -------------------------------------------------------------------------------- 1 | 2 | import { CrudRequest, CreateManyDto, GetManyDefaultResponse, CrudService } from "@nestjsx/crud"; 3 | import { BadRequestException, NotFoundException } from "@nestjs/common"; 4 | import { Model, Document } from 'mongoose' 5 | import { ModelType } from "@typegoose/typegoose/lib/types"; 6 | 7 | 8 | export class MongooseCrudService extends CrudService { 9 | 10 | constructor(public model: Model | ModelType<{}> ) { 11 | super() 12 | } 13 | 14 | buildQuery(req: CrudRequest) { 15 | this.model 16 | let { limit = 10, page = 1, offset: skip = 0, filter = [], fields = [], sort = [], join = [], paramsFilter = [] } = req.parsed 17 | if (page > 1) { 18 | skip = (page - 1) * limit 19 | } 20 | const options = { 21 | page, 22 | skip, 23 | limit, 24 | sort: sort.reduce((acc, v) => (acc[v.field] = v.order === 'ASC' ? 1 : -1, acc), {}), 25 | populate: join.map(v => v.field), 26 | select: fields.join(' ') 27 | } 28 | const where = filter.reduce((acc, { field, operator, value }) => { 29 | let cond = null 30 | switch (operator) { 31 | case 'starts': 32 | cond = new RegExp(`^${value}`, 'i') 33 | break; 34 | case 'ends': 35 | cond = new RegExp(`${value}\$`, 'i') 36 | break; 37 | 38 | case 'cont': 39 | cond = new RegExp(`${value}`, 'i') 40 | break; 41 | case 'excl': 42 | cond = { $ne: new RegExp(`${value}`, 'i') } 43 | break; 44 | case 'notin': 45 | cond = { $nin: value } 46 | break 47 | case 'isnull': 48 | cond = null 49 | break 50 | case 'notnull': 51 | cond = { $ne: null } 52 | break 53 | case 'between': 54 | const [min, max] = value 55 | cond = { $gte: min, $lte: max } 56 | break 57 | default: 58 | cond = { [`\$${operator}`]: value } 59 | } 60 | acc[field] = cond 61 | return acc 62 | }, {}) 63 | const idParam = paramsFilter.find(v => v.field === 'id') 64 | return { options, where, id: idParam ? idParam.value : null } 65 | } 66 | 67 | async getMany(req: CrudRequest) { 68 | 69 | const { options, where } = this.buildQuery(req) 70 | const queryBuilder = this.model.find().setOptions({ 71 | ...options 72 | }).where({ 73 | ...where 74 | }) 75 | options.populate.map(v => { 76 | queryBuilder.populate(v) 77 | }) 78 | 79 | const data = await queryBuilder.exec() 80 | if (options.page) { 81 | const total = await this.model.countDocuments(where) 82 | return this.createPageInfo(data, total, options.limit, options.skip) 83 | } 84 | return data 85 | } 86 | 87 | 88 | async getOne(req: CrudRequest): Promise { 89 | const { options, where, id } = this.buildQuery(req) 90 | const queryBuilder = this.model.findById(id).setOptions({ 91 | ...options 92 | }).where({ 93 | ...where 94 | }) 95 | options.populate.map(v => { 96 | queryBuilder.populate(v) 97 | }) 98 | 99 | const data = await queryBuilder.exec() 100 | 101 | !data && this.throwNotFoundException(this.model.modelName) 102 | 103 | return data 104 | } 105 | async createOne(req: CrudRequest, dto: T): Promise { 106 | return await this.model.create(dto) 107 | } 108 | async createMany(req: CrudRequest, dto: CreateManyDto): Promise { 109 | return await this.model.insertMany(dto.bulk) 110 | } 111 | async updateOne(req: CrudRequest, dto: T): Promise { 112 | const { id } = this.buildQuery(req) 113 | const data = await this.model.findByIdAndUpdate(id, dto, { 114 | new: true, 115 | runValidators: true 116 | }) 117 | !data && this.throwNotFoundException(this.model.modelName) 118 | 119 | return data 120 | } 121 | async replaceOne(req: CrudRequest, dto: T): Promise { 122 | const { id } = this.buildQuery(req) 123 | const data = await this.model.replaceOne({ 124 | _id: id, 125 | }, dto) 126 | !data && this.throwNotFoundException(this.model.modelName) 127 | return this.model.findById(id) 128 | } 129 | async deleteOne(req: CrudRequest): Promise { 130 | const { id } = this.buildQuery(req) 131 | const data = await this.model.findById(id) 132 | !data && this.throwNotFoundException(this.model.modelName) 133 | await this.model.findByIdAndDelete(id) 134 | return data 135 | } 136 | } -------------------------------------------------------------------------------- /src/index.ts: -------------------------------------------------------------------------------- 1 | 2 | export * from './crud-mongoose.service' -------------------------------------------------------------------------------- /tsconfig.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "module": "commonjs", 4 | "declaration": true, 5 | "emitDecoratorMetadata": true, 6 | "experimentalDecorators": true, 7 | "target": "es2018", 8 | "outDir": "dist" 9 | }, 10 | "exclude": ["node_modules", "dist"] 11 | } -------------------------------------------------------------------------------- /yarn.lock: -------------------------------------------------------------------------------- 1 | # THIS IS AN AUTOGENERATED FILE. DO NOT EDIT THIS FILE DIRECTLY. 2 | # yarn lockfile v1 3 | 4 | 5 | "@nestjs/common@^6.7.2": 6 | version "6.7.2" 7 | resolved "https://registry.npm.taobao.org/@nestjs/common/download/@nestjs/common-6.7.2.tgz#4485539992a7aa6824e1993ed20d74159eeaf645" 8 | integrity sha1-RIVTmZKnqmgk4Zk+0g10FZ7q9kU= 9 | dependencies: 10 | axios "0.19.0" 11 | cli-color "1.4.0" 12 | uuid "3.3.3" 13 | 14 | "@nestjsx/crud-request@^4.2.0": 15 | version "4.2.0" 16 | resolved "https://registry.npm.taobao.org/@nestjsx/crud-request/download/@nestjsx/crud-request-4.2.0.tgz#82d81d406157e83e7fa9816ce1f24d03824c24a6" 17 | integrity sha1-gtgdQGFX6D5/qYFs4fJNA4JMJKY= 18 | dependencies: 19 | "@nestjsx/util" "^4.2.0" 20 | 21 | "@nestjsx/crud@^4.2.0": 22 | version "4.2.0" 23 | resolved "https://registry.npm.taobao.org/@nestjsx/crud/download/@nestjsx/crud-4.2.0.tgz#8cb94716f6f7eaa32ad72645056b386468ac71c7" 24 | integrity sha1-jLlHFvb36qMq1yZFBWs4ZGisccc= 25 | dependencies: 26 | "@nestjsx/crud-request" "^4.2.0" 27 | "@nestjsx/util" "^4.2.0" 28 | deepmerge "^3.2.0" 29 | 30 | "@nestjsx/util@^4.2.0": 31 | version "4.2.0" 32 | resolved "https://registry.npm.taobao.org/@nestjsx/util/download/@nestjsx/util-4.2.0.tgz#28a9eab85e01390dcc0d8fd32074256b08ff6c1d" 33 | integrity sha1-KKnquF4BOQ3MDY/TIHQlawj/bB0= 34 | 35 | "@typegoose/typegoose@^6.0.2": 36 | version "6.0.2" 37 | resolved "https://registry.yarnpkg.com/@typegoose/typegoose/-/typegoose-6.0.2.tgz#33087f5c4d71f923d654b0dcc6a02e525dc0609f" 38 | integrity sha512-8WKPJg1Of1gvga9kxewIIXmFpf5Bn3WtCYnJ9JEIHQhf8uDC+8LMnMrXdhYfLMRXW4qIicUJXhDlYsX3idVSUw== 39 | dependencies: 40 | loglevel "^1.6.4" 41 | reflect-metadata "^0.1.13" 42 | 43 | "@types/bson@*": 44 | version "4.0.0" 45 | resolved "https://registry.npm.taobao.org/@types/bson/download/@types/bson-4.0.0.tgz#9073772679d749116eb1dfca56f8eaac6d59cc7a" 46 | integrity sha1-kHN3JnnXSRFusd/KVvjqrG1ZzHo= 47 | dependencies: 48 | "@types/node" "*" 49 | 50 | "@types/mongodb@*": 51 | version "3.3.3" 52 | resolved "https://registry.npm.taobao.org/@types/mongodb/download/@types/mongodb-3.3.3.tgz#749ce52f1d958601dcc4cea3e2839a734c2723e2" 53 | integrity sha1-dJzlLx2VhgHcxM6j4oOac0wnI+I= 54 | dependencies: 55 | "@types/bson" "*" 56 | "@types/node" "*" 57 | 58 | "@types/mongoose@^5.5.18": 59 | version "5.5.18" 60 | resolved "https://registry.npm.taobao.org/@types/mongoose/download/@types/mongoose-5.5.18.tgz#1dcf0efaeb5a813f8311561d098f7259e0761775" 61 | integrity sha1-Hc8O+utagT+DEVYdCY9yWeB2F3U= 62 | dependencies: 63 | "@types/mongodb" "*" 64 | "@types/node" "*" 65 | 66 | "@types/node@*": 67 | version "12.7.8" 68 | resolved "https://registry.npm.taobao.org/@types/node/download/@types/node-12.7.8.tgz?cache=0&sync_timestamp=1569453138457&other_urls=https%3A%2F%2Fregistry.npm.taobao.org%2F%40types%2Fnode%2Fdownload%2F%40types%2Fnode-12.7.8.tgz#cb1bf6800238898bc2ff6ffa5702c3cadd350708" 69 | integrity sha1-yxv2gAI4iYvC/2/6VwLDyt01Bwg= 70 | 71 | ansi-regex@^2.1.1: 72 | version "2.1.1" 73 | resolved "https://registry.npm.taobao.org/ansi-regex/download/ansi-regex-2.1.1.tgz#c3b33ab5ee360d86e0e628f0468ae7ef27d654df" 74 | integrity sha1-w7M6te42DYbg5ijwRorn7yfWVN8= 75 | 76 | axios@0.19.0: 77 | version "0.19.0" 78 | resolved "https://registry.npm.taobao.org/axios/download/axios-0.19.0.tgz?cache=0&other_urls=https%3A%2F%2Fregistry.npm.taobao.org%2Faxios%2Fdownload%2Faxios-0.19.0.tgz#8e09bff3d9122e133f7b8101c8fbdd00ed3d2ab8" 79 | integrity sha1-jgm/89kSLhM/e4EByPvdAO09Krg= 80 | dependencies: 81 | follow-redirects "1.5.10" 82 | is-buffer "^2.0.2" 83 | 84 | cli-color@1.4.0: 85 | version "1.4.0" 86 | resolved "https://registry.npm.taobao.org/cli-color/download/cli-color-1.4.0.tgz?cache=0&other_urls=https%3A%2F%2Fregistry.npm.taobao.org%2Fcli-color%2Fdownload%2Fcli-color-1.4.0.tgz#7d10738f48526824f8fe7da51857cb0f572fe01f" 87 | integrity sha1-fRBzj0hSaCT4/n2lGFfLD1cv4B8= 88 | dependencies: 89 | ansi-regex "^2.1.1" 90 | d "1" 91 | es5-ext "^0.10.46" 92 | es6-iterator "^2.0.3" 93 | memoizee "^0.4.14" 94 | timers-ext "^0.1.5" 95 | 96 | d@1, d@^1.0.1: 97 | version "1.0.1" 98 | resolved "https://registry.npm.taobao.org/d/download/d-1.0.1.tgz?cache=0&sync_timestamp=1560529642619&other_urls=https%3A%2F%2Fregistry.npm.taobao.org%2Fd%2Fdownload%2Fd-1.0.1.tgz#8698095372d58dbee346ffd0c7093f99f8f9eb5a" 99 | integrity sha1-hpgJU3LVjb7jRv/Qxwk/mfj561o= 100 | dependencies: 101 | es5-ext "^0.10.50" 102 | type "^1.0.1" 103 | 104 | debug@=3.1.0: 105 | version "3.1.0" 106 | resolved "https://registry.npm.taobao.org/debug/download/debug-3.1.0.tgz#5bb5a0672628b64149566ba16819e61518c67261" 107 | integrity sha1-W7WgZyYotkFJVmuhaBnmFRjGcmE= 108 | dependencies: 109 | ms "2.0.0" 110 | 111 | deepmerge@^3.2.0: 112 | version "3.3.0" 113 | resolved "https://registry.npm.taobao.org/deepmerge/download/deepmerge-3.3.0.tgz#d3c47fd6f3a93d517b14426b0628a17b0125f5f7" 114 | integrity sha1-08R/1vOpPVF7FEJrBiihewEl9fc= 115 | 116 | es5-ext@^0.10.35, es5-ext@^0.10.45, es5-ext@^0.10.46, es5-ext@^0.10.50, es5-ext@^0.10.51, es5-ext@~0.10.14, es5-ext@~0.10.2, es5-ext@~0.10.46: 117 | version "0.10.51" 118 | resolved "https://registry.npm.taobao.org/es5-ext/download/es5-ext-0.10.51.tgz#ed2d7d9d48a12df86e0299287e93a09ff478842f" 119 | integrity sha1-7S19nUihLfhuApkofpOgn/R4hC8= 120 | dependencies: 121 | es6-iterator "~2.0.3" 122 | es6-symbol "~3.1.1" 123 | next-tick "^1.0.0" 124 | 125 | es6-iterator@^2.0.3, es6-iterator@~2.0.3: 126 | version "2.0.3" 127 | resolved "https://registry.npm.taobao.org/es6-iterator/download/es6-iterator-2.0.3.tgz#a7de889141a05a94b0854403b2d0a0fbfa98f3b7" 128 | integrity sha1-p96IkUGgWpSwhUQDstCg+/qY87c= 129 | dependencies: 130 | d "1" 131 | es5-ext "^0.10.35" 132 | es6-symbol "^3.1.1" 133 | 134 | es6-symbol@^3.1.1, es6-symbol@~3.1.1: 135 | version "3.1.2" 136 | resolved "https://registry.npm.taobao.org/es6-symbol/download/es6-symbol-3.1.2.tgz?cache=0&other_urls=https%3A%2F%2Fregistry.npm.taobao.org%2Fes6-symbol%2Fdownload%2Fes6-symbol-3.1.2.tgz#859fdd34f32e905ff06d752e7171ddd4444a7ed1" 137 | integrity sha1-hZ/dNPMukF/wbXUucXHd1ERKftE= 138 | dependencies: 139 | d "^1.0.1" 140 | es5-ext "^0.10.51" 141 | 142 | es6-weak-map@^2.0.2: 143 | version "2.0.3" 144 | resolved "https://registry.npm.taobao.org/es6-weak-map/download/es6-weak-map-2.0.3.tgz#b6da1f16cc2cc0d9be43e6bdbfc5e7dfcdf31d53" 145 | integrity sha1-ttofFswswNm+Q+a9v8Xn383zHVM= 146 | dependencies: 147 | d "1" 148 | es5-ext "^0.10.46" 149 | es6-iterator "^2.0.3" 150 | es6-symbol "^3.1.1" 151 | 152 | event-emitter@^0.3.5: 153 | version "0.3.5" 154 | resolved "https://registry.npm.taobao.org/event-emitter/download/event-emitter-0.3.5.tgz#df8c69eef1647923c7157b9ce83840610b02cc39" 155 | integrity sha1-34xp7vFkeSPHFXuc6DhAYQsCzDk= 156 | dependencies: 157 | d "1" 158 | es5-ext "~0.10.14" 159 | 160 | follow-redirects@1.5.10: 161 | version "1.5.10" 162 | resolved "https://registry.npm.taobao.org/follow-redirects/download/follow-redirects-1.5.10.tgz#7b7a9f9aea2fdff36786a94ff643ed07f4ff5e2a" 163 | integrity sha1-e3qfmuov3/NnhqlP9kPtB/T/Xio= 164 | dependencies: 165 | debug "=3.1.0" 166 | 167 | is-buffer@^2.0.2: 168 | version "2.0.3" 169 | resolved "https://registry.npm.taobao.org/is-buffer/download/is-buffer-2.0.3.tgz#4ecf3fcf749cbd1e472689e109ac66261a25e725" 170 | integrity sha1-Ts8/z3ScvR5HJonhCaxmJhol5yU= 171 | 172 | is-promise@^2.1: 173 | version "2.1.0" 174 | resolved "https://registry.npm.taobao.org/is-promise/download/is-promise-2.1.0.tgz#79a2a9ece7f096e80f36d2b2f3bc16c1ff4bf3fa" 175 | integrity sha1-eaKp7OfwlugPNtKy87wWwf9L8/o= 176 | 177 | loglevel@^1.6.4: 178 | version "1.6.4" 179 | resolved "https://registry.yarnpkg.com/loglevel/-/loglevel-1.6.4.tgz#f408f4f006db8354d0577dcf6d33485b3cb90d56" 180 | integrity sha512-p0b6mOGKcGa+7nnmKbpzR6qloPbrgLcnio++E+14Vo/XffOGwZtRpUhr8dTH/x2oCMmEoIU0Zwm3ZauhvYD17g== 181 | 182 | lru-queue@0.1: 183 | version "0.1.0" 184 | resolved "https://registry.npm.taobao.org/lru-queue/download/lru-queue-0.1.0.tgz#2738bd9f0d3cf4f84490c5736c48699ac632cda3" 185 | integrity sha1-Jzi9nw089PhEkMVzbEhpmsYyzaM= 186 | dependencies: 187 | es5-ext "~0.10.2" 188 | 189 | memoizee@^0.4.14: 190 | version "0.4.14" 191 | resolved "https://registry.npm.taobao.org/memoizee/download/memoizee-0.4.14.tgz#07a00f204699f9a95c2d9e77218271c7cd610d57" 192 | integrity sha1-B6APIEaZ+alcLZ53IYJxx81hDVc= 193 | dependencies: 194 | d "1" 195 | es5-ext "^0.10.45" 196 | es6-weak-map "^2.0.2" 197 | event-emitter "^0.3.5" 198 | is-promise "^2.1" 199 | lru-queue "0.1" 200 | next-tick "1" 201 | timers-ext "^0.1.5" 202 | 203 | ms@2.0.0: 204 | version "2.0.0" 205 | resolved "https://registry.npm.taobao.org/ms/download/ms-2.0.0.tgz#5608aeadfc00be6c2901df5f9861788de0d597c8" 206 | integrity sha1-VgiurfwAvmwpAd9fmGF4jeDVl8g= 207 | 208 | next-tick@1, next-tick@^1.0.0: 209 | version "1.0.0" 210 | resolved "https://registry.npm.taobao.org/next-tick/download/next-tick-1.0.0.tgz#ca86d1fe8828169b0120208e3dc8424b9db8342c" 211 | integrity sha1-yobR/ogoFpsBICCOPchCS524NCw= 212 | 213 | reflect-metadata@^0.1.13: 214 | version "0.1.13" 215 | resolved "https://registry.yarnpkg.com/reflect-metadata/-/reflect-metadata-0.1.13.tgz#67ae3ca57c972a2aa1642b10fe363fe32d49dc08" 216 | integrity sha512-Ts1Y/anZELhSsjMcU605fU9RE4Oi3p5ORujwbIKXfWa+0Zxs510Qrmrce5/Jowq3cHSZSJqBjypxmHarc+vEWg== 217 | 218 | rxjs@^6.5.3: 219 | version "6.5.3" 220 | resolved "https://registry.npm.taobao.org/rxjs/download/rxjs-6.5.3.tgz#510e26317f4db91a7eb1de77d9dd9ba0a4899a3a" 221 | integrity sha1-UQ4mMX9NuRp+sd532d2boKSJmjo= 222 | dependencies: 223 | tslib "^1.9.0" 224 | 225 | timers-ext@^0.1.5: 226 | version "0.1.7" 227 | resolved "https://registry.npm.taobao.org/timers-ext/download/timers-ext-0.1.7.tgz#6f57ad8578e07a3fb9f91d9387d65647555e25c6" 228 | integrity sha1-b1ethXjgej+5+R2Th9ZWR1VeJcY= 229 | dependencies: 230 | es5-ext "~0.10.46" 231 | next-tick "1" 232 | 233 | tsc@^1.20150623.0: 234 | version "1.20150623.0" 235 | resolved "https://registry.npm.taobao.org/tsc/download/tsc-1.20150623.0.tgz#4ebc3c774e169148cbc768a7342533f082c7a6e5" 236 | integrity sha1-Trw8d04WkUjLx2inNCUz8ILHpuU= 237 | 238 | tslib@^1.9.0: 239 | version "1.10.0" 240 | resolved "https://registry.npm.taobao.org/tslib/download/tslib-1.10.0.tgz#c3c19f95973fb0a62973fb09d90d961ee43e5c8a" 241 | integrity sha1-w8GflZc/sKYpc/sJ2Q2WHuQ+XIo= 242 | 243 | type@^1.0.1: 244 | version "1.2.0" 245 | resolved "https://registry.npm.taobao.org/type/download/type-1.2.0.tgz#848dd7698dafa3e54a6c479e759c4bc3f18847a0" 246 | integrity sha1-hI3XaY2vo+VKbEeedZxLw/GIR6A= 247 | 248 | typescript@^3.6.3: 249 | version "3.6.3" 250 | resolved "https://registry.npm.taobao.org/typescript/download/typescript-3.6.3.tgz?cache=0&other_urls=https%3A%2F%2Fregistry.npm.taobao.org%2Ftypescript%2Fdownload%2Ftypescript-3.6.3.tgz#fea942fabb20f7e1ca7164ff626f1a9f3f70b4da" 251 | integrity sha1-/qlC+rsg9+HKcWT/Ym8anz9wtNo= 252 | 253 | uuid@3.3.3: 254 | version "3.3.3" 255 | resolved "https://registry.npm.taobao.org/uuid/download/uuid-3.3.3.tgz#4568f0216e78760ee1dbf3a4d2cf53e224112866" 256 | integrity sha1-RWjwIW54dg7h2/Ok0s9T4iQRKGY= 257 | --------------------------------------------------------------------------------