{"name":"get-amd-module-type","version":"2.0.5","description":"Get the type of AMD module used for an AST node or within a file","main":"index.js","directories":{"test":"test"},"scripts":{"test":"mocha test/test.js"},"repository":{"type":"git","url":"git+https://github.com/mrjoelkemp/node-get-amd-module-type.git"},"keywords":["module","type","amd","factory","form"],"author":{"name":"Joel Kemp","email":"joel@mrjoelkemp.com"},"license":"MIT","bugs":{"url":"https://github.com/mrjoelkemp/node-get-amd-module-type/issues"},"homepage":"https://github.com/mrjoelkemp/node-get-amd-module-type","devDependencies":{"mocha":"~2.0.1"},"dependencies":{"ast-module-types":"^2.3.2","node-source-walk":"^3.2.0"},"gitHead":"eaee940e83b13e2d6d99b9f985fc05f489306eae","_id":"get-amd-module-type@2.0.5","_shasum":"e671ec5a96ad5fbf53a3a22a289e9238c772ddb0","_from":".","_npmVersion":"3.10.3","_nodeVersion":"6.3.1","_npmUser":{"name":"mrjoelkemp","email":"joel@mrjoelkemp.com"},"maintainers":[{"name":"mrjoelkemp","email":"joel@mrjoelkemp.com"}],"dist":{"shasum":"e671ec5a96ad5fbf53a3a22a289e9238c772ddb0","tarball":"http://registry-npm.ywwl.com/get-amd-module-type/download/get-amd-module-type-2.0.5.tgz","integrity":"sha512-ScWV7OFmLmoab7zw065zMD0iR8/zg4TqjH3rpElGbhJEikS4R/dErxox9M8wJMWhUsZqX37PbtDI9fNz9LMkWQ==","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIQCsYIc/8lBGuTf9LhEHSLzYTjWnol58VHW4W0Qbp09GRAIgRIxsAwcWk3ddXnWCt691u+wbi1aXI4sDkCne3+O8Q14="}],"size":1654,"noattachment":false,"key":"/get-amd-module-type/-/get-amd-module-type-2.0.5.tgz"},"_npmOperationalInternal":{"host":"packages-16-east.internal.npmjs.com","tmp":"tmp/get-amd-module-type-2.0.5.tgz_1473094772561_0.2968246336095035"},"readme":"# get-amd-module-type\n\n[![CI](https://img.shields.io/github/actions/workflow/status/dependents/node-get-amd-module-type/ci.yml?branch=main&label=CI&logo=github)](https://github.com/dependents/node-get-amd-module-type/actions/workflows/ci.yml?query=branch%3Amain)\n[![npm version](https://img.shields.io/npm/v/get-amd-module-type?logo=npm&logoColor=fff)](https://www.npmjs.com/package/get-amd-module-type)\n[![npm downloads](https://img.shields.io/npm/dm/get-amd-module-type)](https://www.npmjs.com/package/get-amd-module-type)\n\n> Get the type of an AMD module used for an AST node or within a file\n\n```sh\nnpm install get-amd-module-type\n```\n\n## Usage\n\n```js\nconst getType = require('get-amd-module-type');\n\n// Async\ngetType('my/file.js', (error, type) => {\n  if (error) throw error;\n  console.log(type);\n});\n\nlet type;\n\n// Sync\ntype = getType.sync('my/file.js');\n\n// From source code\ntype = getType.fromSource('define() {}');\n\n// From an AST node\ntype = getType.fromAST(node);\n```\n\nThe returned `type` will be any of the following:\n\n* `'named'`: `define('name', [deps], func)`\n* `'deps'`: `define([deps], func)`\n* `'rem'`: `define(function(require, exports, module){});`\n* `'factory'`: `define(function(require){})`\n* `'nodeps'`: `define({})`\n* `'driver'`: `require([deps], function)`\n\n## License\n\n[MIT](LICENSE)\n","publish_time":1473094773191,"_cnpm_publish_time":1473094773191,"dist-tags":{"latest":"7.0.0"}}