{"name":"code-context","description":"Parse a string of javascript to determine the context for functions, variables and comments based on the code that follows.","version":"0.5.3","homepage":"https://github.com/jonschlinkert/code-context","author":{"name":"Jon Schlinkert","url":"https://github.com/jonschlinkert"},"repository":{"type":"git","url":"git+https://github.com/jonschlinkert/code-context.git"},"bugs":{"url":"https://github.com/jonschlinkert/code-context/issues"},"license":"MIT","files":["index.js"],"main":"index.js","engines":{"node":">=0.10.0"},"scripts":{"test":"mocha"},"dependencies":{"parse-code-context":"^0.1.3"},"devDependencies":{"fs-utils":"^0.4.3","mocha":"*","should":"^4.0.4"},"keywords":["code","comment","context","declaration","docs","documentation","expression","extract","function","javascript","js","method","parse","property","prototype","statement"],"gitHead":"995fb6e2c52fc6c07519896f117be8f843af0d65","_id":"code-context@0.5.3","_shasum":"e368c7bd247d3ac71100d91b5fd02e4e66fa9022","_from":".","_npmVersion":"2.10.1","_nodeVersion":"0.12.4","_npmUser":{"name":"jonschlinkert","email":"github@sellside.com"},"maintainers":[{"name":"jonschlinkert","email":"github@sellside.com"},{"name":"doowb","email":"brian.woodward@gmail.com"}],"dist":{"shasum":"e368c7bd247d3ac71100d91b5fd02e4e66fa9022","tarball":"http://registry-npm.ywwl.com/code-context/download/code-context-0.5.3.tgz","integrity":"sha512-tHQ18LiAUmSut1OQ2d4ZWzbyUyUZroWS221GA1wYK/TzYA4j6VvqvcCuT6JMhG32My5k/MpDD3lothIScEWG1w==","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEQCICkE6WoEHJV2252kmStisN5M4Y5qGIJGEEBJxrRD7cWpAiB9aTE4nXlIdOhIahsMNJxRFDIRmHBmdkTyarpr/AtRvg=="}],"size":2397,"noattachment":false,"key":"/code-context/-/code-context-0.5.3.tgz"},"directories":{},"readme":"# code-context [![NPM version](https://badge.fury.io/js/code-context.svg)](http://badge.fury.io/js/code-context)  [![Build Status](https://travis-ci.org/jonschlinkert/code-context.svg)](https://travis-ci.org/jonschlinkert/code-context)\n\n> Parse a string of javascript to determine the context for functions, variables and comments based on the code that follows.\n\n**Currently supports:**\n\n* code comments\n* function statements\n* function expressions\n* prototype methods\n* prototype properties\n* methods\n* properties\n* declarations\n\n## Install\n\nInstall with [npm](https://www.npmjs.com/)\n\n```sh\n$ npm i code-context --save\n```\n\n## Usage\n\n```js\nvar parseContext = require('code-context');\n```\n\nGiven the following code in `my-app.js`:\n\n```js\n/**\n * My app\n */\nvar app = function(str) {\n  return str\n};\n```\n\nPass `my-app.js` as a string:\n\n```js\nvar str = fs.readFileSync('my-app.js', 'utf8');\nvar context = parseContext(str);\n```\n\nResults in:\n\n```js\n[{\n  type: 'comment',\n  begin: 1,\n  end: 3\n},\n{\n  begin: 4,\n  type: 'function',\n  name: 'app',\n  string: 'app()',\n  original: 'var app = function(str) {'\n}]\n```\n\n## Related projects\n\n* [extract-comments](https://github.com/jonschlinkert/extract-comments): Extract code comments from string or from a glob of files.\n* [parse-code-context](https://github.com/jonschlinkert/parse-code-context): Parse code context in a single line of javascript, for functions, variable declarations, methods, prototype… [more](https://github.com/jonschlinkert/parse-code-context)\n* [parse-comments](https://github.com/jonschlinkert/parse-comments): Parse code comments from JavaScript or any language that uses the same format.\n\n## Running tests\n\nInstall dev dependencies:\n\n```sh\n$ npm i -d && npm test\n```\n\n## Contributing\n\nPull requests and stars are always welcome. For bugs and feature requests, [please create an issue](https://github.com/jonschlinkert/code-context/issues/new)\n\n## Authors\n\n**Jon Schlinkert**\n\n+ [github/jonschlinkert](https://github.com/jonschlinkert)\n+ [twitter/jonschlinkert](http://twitter.com/jonschlinkert)\n\n## License\n\nCopyright © 2015 Jon Schlinkert\nReleased under the MIT license.\n\n***\n\n_This file was generated by [verb-cli](https://github.com/assemble/verb-cli) on August 01, 2015._","publish_time":1438406115641,"_cnpm_publish_time":1438406115641,"dist-tags":{"latest":"0.5.3"}}