UNPKG

mongoose-data-seed

Version:

Seed mongodb with data using mongoose models

1,035 lines 21.3 kB
{ "type": "File", "start": 0, "end": 177, "loc": { "start": { "line": 1, "column": 0 }, "end": { "line": 4, "column": 0 } }, "program": { "type": "Program", "start": 0, "end": 177, "loc": { "start": { "line": 1, "column": 0 }, "end": { "line": 4, "column": 0 } }, "sourceType": "module", "body": [ { "type": "ExportNamedDeclaration", "start": 0, "end": 51, "loc": { "start": { "line": 1, "column": 0 }, "end": { "line": 1, "column": 51 } }, "declaration": null, "specifiers": [ { "type": "ExportSpecifier", "start": 9, "end": 29, "loc": { "start": { "line": 1, "column": 9 }, "end": { "line": 1, "column": 29 } }, "local": { "type": "Identifier", "start": 9, "end": 16, "loc": { "start": { "line": 1, "column": 9 }, "end": { "line": 1, "column": 16 }, "identifierName": "default" }, "name": "default" }, "exported": { "type": "Identifier", "start": 20, "end": 29, "loc": { "start": { "line": 1, "column": 20 }, "end": { "line": 1, "column": 29 }, "identifierName": "Installer" }, "name": "Installer" } } ], "source": { "type": "StringLiteral", "start": 37, "end": 50, "loc": { "start": { "line": 1, "column": 37 }, "end": { "line": 1, "column": 50 } }, "extra": { "rawValue": "./installer", "raw": "'./installer'" }, "value": "./installer" } }, { "type": "ExportNamedDeclaration", "start": 52, "end": 116, "loc": { "start": { "line": 2, "column": 0 }, "end": { "line": 2, "column": 64 } }, "declaration": null, "specifiers": [ { "type": "ExportSpecifier", "start": 61, "end": 87, "loc": { "start": { "line": 2, "column": 9 }, "end": { "line": 2, "column": 35 } }, "local": { "type": "Identifier", "start": 61, "end": 68, "loc": { "start": { "line": 2, "column": 9 }, "end": { "line": 2, "column": 16 }, "identifierName": "default" }, "name": "default" }, "exported": { "type": "Identifier", "start": 72, "end": 87, "loc": { "start": { "line": 2, "column": 20 }, "end": { "line": 2, "column": 35 }, "identifierName": "SeederGenerator" }, "name": "SeederGenerator" } } ], "source": { "type": "StringLiteral", "start": 95, "end": 115, "loc": { "start": { "line": 2, "column": 43 }, "end": { "line": 2, "column": 63 } }, "extra": { "rawValue": "./seeder-generator", "raw": "'./seeder-generator'" }, "value": "./seeder-generator" } }, { "type": "ExportNamedDeclaration", "start": 117, "end": 176, "loc": { "start": { "line": 3, "column": 0 }, "end": { "line": 3, "column": 59 } }, "declaration": null, "specifiers": [ { "type": "ExportSpecifier", "start": 126, "end": 149, "loc": { "start": { "line": 3, "column": 9 }, "end": { "line": 3, "column": 32 } }, "local": { "type": "Identifier", "start": 126, "end": 133, "loc": { "start": { "line": 3, "column": 9 }, "end": { "line": 3, "column": 16 }, "identifierName": "default" }, "name": "default" }, "exported": { "type": "Identifier", "start": 137, "end": 149, "loc": { "start": { "line": 3, "column": 20 }, "end": { "line": 3, "column": 32 }, "identifierName": "MdSeedRunner" }, "name": "MdSeedRunner" } } ], "source": { "type": "StringLiteral", "start": 157, "end": 175, "loc": { "start": { "line": 3, "column": 40 }, "end": { "line": 3, "column": 58 } }, "extra": { "rawValue": "./md-seed-runner", "raw": "'./md-seed-runner'" }, "value": "./md-seed-runner" } } ], "directives": [] }, "comments": [], "tokens": [ { "type": { "label": "export", "keyword": "export", "beforeExpr": false, "startsExpr": false, "rightAssociative": false, "isLoop": false, "isAssign": false, "prefix": false, "postfix": false, "binop": null, "updateContext": null }, "value": "export", "start": 0, "end": 6, "loc": { "start": { "line": 1, "column": 0 }, "end": { "line": 1, "column": 6 } } }, { "type": { "label": "{", "beforeExpr": true, "startsExpr": true, "rightAssociative": false, "isLoop": false, "isAssign": false, "prefix": false, "postfix": false, "binop": null }, "start": 7, "end": 8, "loc": { "start": { "line": 1, "column": 7 }, "end": { "line": 1, "column": 8 } } }, { "type": { "label": "default", "keyword": "default", "beforeExpr": true, "startsExpr": false, "rightAssociative": false, "isLoop": false, "isAssign": false, "prefix": false, "postfix": false, "binop": null, "updateContext": null }, "value": "default", "start": 9, "end": 16, "loc": { "start": { "line": 1, "column": 9 }, "end": { "line": 1, "column": 16 } } }, { "type": { "label": "name", "beforeExpr": false, "startsExpr": true, "rightAssociative": false, "isLoop": false, "isAssign": false, "prefix": false, "postfix": false, "binop": null }, "value": "as", "start": 17, "end": 19, "loc": { "start": { "line": 1, "column": 17 }, "end": { "line": 1, "column": 19 } } }, { "type": { "label": "name", "beforeExpr": false, "startsExpr": true, "rightAssociative": false, "isLoop": false, "isAssign": false, "prefix": false, "postfix": false, "binop": null }, "value": "Installer", "start": 20, "end": 29, "loc": { "start": { "line": 1, "column": 20 }, "end": { "line": 1, "column": 29 } } }, { "type": { "label": "}", "beforeExpr": false, "startsExpr": false, "rightAssociative": false, "isLoop": false, "isAssign": false, "prefix": false, "postfix": false, "binop": null }, "start": 30, "end": 31, "loc": { "start": { "line": 1, "column": 30 }, "end": { "line": 1, "column": 31 } } }, { "type": { "label": "name", "beforeExpr": false, "startsExpr": true, "rightAssociative": false, "isLoop": false, "isAssign": false, "prefix": false, "postfix": false, "binop": null }, "value": "from", "start": 32, "end": 36, "loc": { "start": { "line": 1, "column": 32 }, "end": { "line": 1, "column": 36 } } }, { "type": { "label": "string", "beforeExpr": false, "startsExpr": true, "rightAssociative": false, "isLoop": false, "isAssign": false, "prefix": false, "postfix": false, "binop": null, "updateContext": null }, "value": "./installer", "start": 37, "end": 50, "loc": { "start": { "line": 1, "column": 37 }, "end": { "line": 1, "column": 50 } } }, { "type": { "label": ";", "beforeExpr": true, "startsExpr": false, "rightAssociative": false, "isLoop": false, "isAssign": false, "prefix": false, "postfix": false, "binop": null, "updateContext": null }, "start": 50, "end": 51, "loc": { "start": { "line": 1, "column": 50 }, "end": { "line": 1, "column": 51 } } }, { "type": { "label": "export", "keyword": "export", "beforeExpr": false, "startsExpr": false, "rightAssociative": false, "isLoop": false, "isAssign": false, "prefix": false, "postfix": false, "binop": null, "updateContext": null }, "value": "export", "start": 52, "end": 58, "loc": { "start": { "line": 2, "column": 0 }, "end": { "line": 2, "column": 6 } } }, { "type": { "label": "{", "beforeExpr": true, "startsExpr": true, "rightAssociative": false, "isLoop": false, "isAssign": false, "prefix": false, "postfix": false, "binop": null }, "start": 59, "end": 60, "loc": { "start": { "line": 2, "column": 7 }, "end": { "line": 2, "column": 8 } } }, { "type": { "label": "default", "keyword": "default", "beforeExpr": true, "startsExpr": false, "rightAssociative": false, "isLoop": false, "isAssign": false, "prefix": false, "postfix": false, "binop": null, "updateContext": null }, "value": "default", "start": 61, "end": 68, "loc": { "start": { "line": 2, "column": 9 }, "end": { "line": 2, "column": 16 } } }, { "type": { "label": "name", "beforeExpr": false, "startsExpr": true, "rightAssociative": false, "isLoop": false, "isAssign": false, "prefix": false, "postfix": false, "binop": null }, "value": "as", "start": 69, "end": 71, "loc": { "start": { "line": 2, "column": 17 }, "end": { "line": 2, "column": 19 } } }, { "type": { "label": "name", "beforeExpr": false, "startsExpr": true, "rightAssociative": false, "isLoop": false, "isAssign": false, "prefix": false, "postfix": false, "binop": null }, "value": "SeederGenerator", "start": 72, "end": 87, "loc": { "start": { "line": 2, "column": 20 }, "end": { "line": 2, "column": 35 } } }, { "type": { "label": "}", "beforeExpr": false, "startsExpr": false, "rightAssociative": false, "isLoop": false, "isAssign": false, "prefix": false, "postfix": false, "binop": null }, "start": 88, "end": 89, "loc": { "start": { "line": 2, "column": 36 }, "end": { "line": 2, "column": 37 } } }, { "type": { "label": "name", "beforeExpr": false, "startsExpr": true, "rightAssociative": false, "isLoop": false, "isAssign": false, "prefix": false, "postfix": false, "binop": null }, "value": "from", "start": 90, "end": 94, "loc": { "start": { "line": 2, "column": 38 }, "end": { "line": 2, "column": 42 } } }, { "type": { "label": "string", "beforeExpr": false, "startsExpr": true, "rightAssociative": false, "isLoop": false, "isAssign": false, "prefix": false, "postfix": false, "binop": null, "updateContext": null }, "value": "./seeder-generator", "start": 95, "end": 115, "loc": { "start": { "line": 2, "column": 43 }, "end": { "line": 2, "column": 63 } } }, { "type": { "label": ";", "beforeExpr": true, "startsExpr": false, "rightAssociative": false, "isLoop": false, "isAssign": false, "prefix": false, "postfix": false, "binop": null, "updateContext": null }, "start": 115, "end": 116, "loc": { "start": { "line": 2, "column": 63 }, "end": { "line": 2, "column": 64 } } }, { "type": { "label": "export", "keyword": "export", "beforeExpr": false, "startsExpr": false, "rightAssociative": false, "isLoop": false, "isAssign": false, "prefix": false, "postfix": false, "binop": null, "updateContext": null }, "value": "export", "start": 117, "end": 123, "loc": { "start": { "line": 3, "column": 0 }, "end": { "line": 3, "column": 6 } } }, { "type": { "label": "{", "beforeExpr": true, "startsExpr": true, "rightAssociative": false, "isLoop": false, "isAssign": false, "prefix": false, "postfix": false, "binop": null }, "start": 124, "end": 125, "loc": { "start": { "line": 3, "column": 7 }, "end": { "line": 3, "column": 8 } } }, { "type": { "label": "default", "keyword": "default", "beforeExpr": true, "startsExpr": false, "rightAssociative": false, "isLoop": false, "isAssign": false, "prefix": false, "postfix": false, "binop": null, "updateContext": null }, "value": "default", "start": 126, "end": 133, "loc": { "start": { "line": 3, "column": 9 }, "end": { "line": 3, "column": 16 } } }, { "type": { "label": "name", "beforeExpr": false, "startsExpr": true, "rightAssociative": false, "isLoop": false, "isAssign": false, "prefix": false, "postfix": false, "binop": null }, "value": "as", "start": 134, "end": 136, "loc": { "start": { "line": 3, "column": 17 }, "end": { "line": 3, "column": 19 } } }, { "type": { "label": "name", "beforeExpr": false, "startsExpr": true, "rightAssociative": false, "isLoop": false, "isAssign": false, "prefix": false, "postfix": false, "binop": null }, "value": "MdSeedRunner", "start": 137, "end": 149, "loc": { "start": { "line": 3, "column": 20 }, "end": { "line": 3, "column": 32 } } }, { "type": { "label": "}", "beforeExpr": false, "startsExpr": false, "rightAssociative": false, "isLoop": false, "isAssign": false, "prefix": false, "postfix": false, "binop": null }, "start": 150, "end": 151, "loc": { "start": { "line": 3, "column": 33 }, "end": { "line": 3, "column": 34 } } }, { "type": { "label": "name", "beforeExpr": false, "startsExpr": true, "rightAssociative": false, "isLoop": false, "isAssign": false, "prefix": false, "postfix": false, "binop": null }, "value": "from", "start": 152, "end": 156, "loc": { "start": { "line": 3, "column": 35 }, "end": { "line": 3, "column": 39 } } }, { "type": { "label": "string", "beforeExpr": false, "startsExpr": true, "rightAssociative": false, "isLoop": false, "isAssign": false, "prefix": false, "postfix": false, "binop": null, "updateContext": null }, "value": "./md-seed-runner", "start": 157, "end": 175, "loc": { "start": { "line": 3, "column": 40 }, "end": { "line": 3, "column": 58 } } }, { "type": { "label": ";", "beforeExpr": true, "startsExpr": false, "rightAssociative": false, "isLoop": false, "isAssign": false, "prefix": false, "postfix": false, "binop": null, "updateContext": null }, "start": 175, "end": 176, "loc": { "start": { "line": 3, "column": 58 }, "end": { "line": 3, "column": 59 } } }, { "type": { "label": "eof", "beforeExpr": false, "startsExpr": false, "rightAssociative": false, "isLoop": false, "isAssign": false, "prefix": false, "postfix": false, "binop": null, "updateContext": null }, "start": 177, "end": 177, "loc": { "start": { "line": 4, "column": 0 }, "end": { "line": 4, "column": 0 } } } ] }