{"_id":"@bconnorwhite/module","_rev":"139421","name":"@bconnorwhite/module","description":"Read your module's package.json without importing it","dist-tags":{"latest":"2.0.2"},"maintainers":[{"name":"bconnorwhite","email":"connor.bcw@gmail.com"}],"time":{"modified":"2021-06-03T11:25:54.000Z","created":"2020-08-17T02:55:13.409Z","2.0.2":"2020-09-09T02:07:37.557Z","2.0.1":"2020-09-09T01:57:31.856Z","2.0.0":"2020-09-09T01:52:15.971Z","1.0.6":"2020-09-02T04:22:28.488Z","1.0.5":"2020-09-02T03:36:34.862Z","1.0.4":"2020-08-17T04:53:47.393Z","1.0.3":"2020-08-17T04:46:08.992Z","1.0.2":"2020-08-17T03:21:55.892Z","1.0.1":"2020-08-17T02:59:08.234Z","1.0.0":"2020-08-17T02:55:13.409Z"},"users":{},"author":{"name":"Connor White","email":"connor.bcw@gmail.com","url":"https://connorwhite.org"},"repository":{"type":"git","url":"git+https://github.com/bconnorwhite/module.git"},"versions":{"2.0.2":{"name":"@bconnorwhite/module","version":"2.0.2","description":"Read your module's package.json without importing it","license":"MIT","author":{"name":"Connor White","email":"connor.bcw@gmail.com","url":"https://connorwhite.org"},"homepage":"https://connorwhite.org/github/module","repository":{"type":"git","url":"git+https://github.com/bconnorwhite/module.git"},"keywords":["version","read","package","pkg","json","module"],"main":"./build/index.js","scripts":{"build":"bob build","postversion":"git push","prepublishOnly":"yarn build"},"dependencies":{"find-up":"^5.0.0","read-json-safe":"^1.0.5","types-pkg-json":"^1.1.0"},"devDependencies":{"@bconnorwhite/bob":"^2.1.0","@types/node":"^14.6.4"},"_id":"@bconnorwhite/module@2.0.2","dist":{"shasum":"557846110bb89412e9689ac778358bc2b1af0c4a","size":2745,"noattachment":false,"key":"/@bconnorwhite/module/-/@bconnorwhite/module-2.0.2.tgz","tarball":"http://registry.cnpm.dingdandao.com/@bconnorwhite/module/download/@bconnorwhite/module-2.0.2.tgz"},"maintainers":[{"name":"bconnorwhite","email":"connor.bcw@gmail.com"}],"_npmUser":{"name":"bconnorwhite","email":"connor.bcw@gmail.com"},"directories":{},"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/module_2.0.2_1599617257452_0.6571609599437527"},"_hasShrinkwrap":false,"publish_time":1599617257557,"_cnpm_publish_time":1599617257557},"2.0.1":{"name":"@bconnorwhite/module","version":"2.0.1","description":"Read your module's package.json without importing it","license":"MIT","author":{"name":"Connor White","email":"connor.bcw@gmail.com","url":"https://connorwhite.org"},"homepage":"https://connorwhite.org/github/module","repository":{"type":"git","url":"git+https://github.com/bconnorwhite/module.git"},"keywords":["version","read","package","pkg","json","module"],"main":"./build/index.js","scripts":{"build":"bob build","postversion":"git push","prepublishOnly":"yarn build"},"dependencies":{"read-json-safe":"^1.0.5","types-pkg-json":"^1.1.0"},"devDependencies":{"@bconnorwhite/bob":"^2.1.0","@types/node":"^14.6.4"},"_id":"@bconnorwhite/module@2.0.1","dist":{"shasum":"d1006435aab008a6a8c5d7cc58ede75bcf0dd6b9","size":2363,"noattachment":false,"key":"/@bconnorwhite/module/-/@bconnorwhite/module-2.0.1.tgz","tarball":"http://registry.cnpm.dingdandao.com/@bconnorwhite/module/download/@bconnorwhite/module-2.0.1.tgz"},"maintainers":[{"name":"bconnorwhite","email":"connor.bcw@gmail.com"}],"_npmUser":{"name":"bconnorwhite","email":"connor.bcw@gmail.com"},"directories":{},"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/module_2.0.1_1599616651578_0.5125079412226115"},"_hasShrinkwrap":false,"publish_time":1599616651856,"_cnpm_publish_time":1599616651856},"2.0.0":{"name":"@bconnorwhite/module","version":"2.0.0","description":"Read your module's package.json without importing it","license":"MIT","author":{"name":"Connor White","email":"connor.bcw@gmail.com","url":"https://connorwhite.org"},"homepage":"https://connorwhite.org/github/module","repository":{"type":"git","url":"git+https://github.com/bconnorwhite/module.git"},"keywords":["version","read","package","pkg","json","module"],"main":"./build/index.js","scripts":{"build":"bob build","postversion":"git push","prepublishOnly":"yarn build"},"dependencies":{"read-json-safe":"^1.0.5","types-pkg-json":"^1.0.2"},"devDependencies":{"@bconnorwhite/bob":"^2.1.0","@types/node":"^14.6.4"},"_id":"@bconnorwhite/module@2.0.0","dist":{"shasum":"31825dacd8b51014e5088f31f7428ca29f2341b4","size":2423,"noattachment":false,"key":"/@bconnorwhite/module/-/@bconnorwhite/module-2.0.0.tgz","tarball":"http://registry.cnpm.dingdandao.com/@bconnorwhite/module/download/@bconnorwhite/module-2.0.0.tgz"},"maintainers":[{"name":"bconnorwhite","email":"connor.bcw@gmail.com"}],"_npmUser":{"name":"bconnorwhite","email":"connor.bcw@gmail.com"},"directories":{},"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/module_2.0.0_1599616335241_0.020700502731222592"},"_hasShrinkwrap":false,"publish_time":1599616335971,"_cnpm_publish_time":1599616335971},"1.0.6":{"name":"@bconnorwhite/module","version":"1.0.6","description":"Set commander version based on your module's package.json.","author":{"name":"Connor White"},"license":"MIT","keywords":["commander","version","read","package","json","module"],"repository":{"type":"git","url":"git+https://github.com/bconnorwhite/module.git"},"main":"./build/index.js","scripts":{"build":"bob build","prepublishOnly":"yarn build"},"dependencies":{"commander":"^6.0.0","find-up":"^5.0.0","read-json-safe":"^1.0.4"},"devDependencies":{"@bconnorwhite/bob":"^1.9.7","@types/node":"^14.0.27","type-fest":"^0.16.0"},"_id":"@bconnorwhite/module@1.0.6","dist":{"shasum":"97b6044116c361b69ca1ac43ad0328b458de6991","size":1686,"noattachment":false,"key":"/@bconnorwhite/module/-/@bconnorwhite/module-1.0.6.tgz","tarball":"http://registry.cnpm.dingdandao.com/@bconnorwhite/module/download/@bconnorwhite/module-1.0.6.tgz"},"maintainers":[{"name":"bconnorwhite","email":"connor.bcw@gmail.com"}],"_npmUser":{"name":"bconnorwhite","email":"connor.bcw@gmail.com"},"directories":{},"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/module_1.0.6_1599020548321_0.5588145916199678"},"_hasShrinkwrap":false,"publish_time":1599020548488,"_cnpm_publish_time":1599020548488},"1.0.5":{"name":"@bconnorwhite/module","version":"1.0.5","description":"Set commander version based on your module's package.json.","author":{"name":"Connor White"},"license":"MIT","keywords":["commander","version","read","package","json","module"],"repository":{"type":"git","url":"git+https://github.com/bconnorwhite/module.git"},"main":"./build/index.js","scripts":{"build":"bob build","prepublishOnly":"yarn build"},"dependencies":{"commander":"^6.0.0","find-up":"^5.0.0","read-json-safe":"^1.0.3"},"devDependencies":{"@bconnorwhite/bob":"^1.9.6","@types/node":"^14.0.27","type-fest":"^0.16.0"},"_id":"@bconnorwhite/module@1.0.5","dist":{"shasum":"ea45104c5347502a3426b161a1bc5f9aebe221b5","size":1689,"noattachment":false,"key":"/@bconnorwhite/module/-/@bconnorwhite/module-1.0.5.tgz","tarball":"http://registry.cnpm.dingdandao.com/@bconnorwhite/module/download/@bconnorwhite/module-1.0.5.tgz"},"maintainers":[{"name":"bconnorwhite","email":"connor.bcw@gmail.com"}],"_npmUser":{"name":"bconnorwhite","email":"connor.bcw@gmail.com"},"directories":{},"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/module_1.0.5_1599017794744_0.5967317957280394"},"_hasShrinkwrap":false,"publish_time":1599017794862,"_cnpm_publish_time":1599017794862},"1.0.4":{"name":"@bconnorwhite/module","version":"1.0.4","description":"Set commander version based on your module's package.json.","author":{"name":"Connor White"},"license":"MIT","keywords":["commander","version","read","package","json","module"],"repository":{"type":"git","url":"git+https://github.com/bconnorwhite/module.git"},"main":"./build/index.js","scripts":{"build":"babel ./src --out-dir ./build --config-file ./babel.config.json --extensions .ts --delete-dir-on-start && tsc --project ./tsconfig.json","prepublishOnly":"yarn build"},"dependencies":{"commander":"^6.0.0","find-up":"^5.0.0","read-json-safe":"^1.0.1"},"devDependencies":{"@babel/cli":"^7.10.5","@babel/core":"^7.11.1","@babel/plugin-transform-runtime":"^7.11.0","@babel/preset-env":"^7.11.0","@babel/preset-typescript":"^7.10.4","@types/node":"^14.0.27","type-fest":"^0.16.0","typescript":"^3.9.7"},"_id":"@bconnorwhite/module@1.0.4","dist":{"shasum":"faec96a895b3f85d4f344734007cbf63573e4b1b","size":1509,"noattachment":false,"key":"/@bconnorwhite/module/-/@bconnorwhite/module-1.0.4.tgz","tarball":"http://registry.cnpm.dingdandao.com/@bconnorwhite/module/download/@bconnorwhite/module-1.0.4.tgz"},"maintainers":[{"name":"bconnorwhite","email":"connor.bcw@gmail.com"}],"_npmUser":{"name":"bconnorwhite","email":"connor.bcw@gmail.com"},"directories":{},"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/module_1.0.4_1597640027221_0.6287145199540869"},"_hasShrinkwrap":false,"publish_time":1597640027393,"_cnpm_publish_time":1597640027393},"1.0.3":{"name":"@bconnorwhite/module","version":"1.0.3","description":"Set commander version based on your module's package.json.","author":{"name":"Connor White"},"license":"MIT","keywords":["commander","version","read","package","json","module"],"repository":{"type":"git","url":"git+https://github.com/bconnorwhite/module.git"},"main":"./build/index.js","scripts":{"build":"babel ./src --out-dir ./build --config-file ./babel.config.json --extensions .ts --delete-dir-on-start && tsc --project ./tsconfig.json","prepublishOnly":"yarn build"},"dependencies":{"commander":"^6.0.0","read-json-safe":"^1.0.1"},"devDependencies":{"@babel/cli":"^7.10.5","@babel/core":"^7.11.1","@babel/plugin-transform-runtime":"^7.11.0","@babel/preset-env":"^7.11.0","@babel/preset-typescript":"^7.10.4","@types/node":"^14.0.27","type-fest":"^0.16.0","typescript":"^3.9.7"},"_id":"@bconnorwhite/module@1.0.3","dist":{"shasum":"b4d91b192ab0c40c7e91e528907882424af278b5","size":1462,"noattachment":false,"key":"/@bconnorwhite/module/-/@bconnorwhite/module-1.0.3.tgz","tarball":"http://registry.cnpm.dingdandao.com/@bconnorwhite/module/download/@bconnorwhite/module-1.0.3.tgz"},"maintainers":[{"name":"bconnorwhite","email":"connor.bcw@gmail.com"}],"_npmUser":{"name":"bconnorwhite","email":"connor.bcw@gmail.com"},"directories":{},"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/module_1.0.3_1597639568871_0.6955811524679647"},"_hasShrinkwrap":false,"publish_time":1597639568992,"_cnpm_publish_time":1597639568992},"1.0.2":{"name":"@bconnorwhite/module","version":"1.0.2","description":"Set commander version based on your module's package.json.","author":{"name":"Connor White"},"license":"MIT","keywords":["commander","version","read","package","json","module"],"repository":{"type":"git","url":"git+https://github.com/bconnorwhite/module.git"},"main":"./build/index.js","scripts":{"build":"babel ./src --out-dir ./build --config-file ./babel.config.json --extensions .ts --delete-dir-on-start && tsc --project ./tsconfig.json","prepublishOnly":"yarn build"},"dependencies":{"commander":"^6.0.0","read-json-safe":"^1.0.1"},"devDependencies":{"@babel/cli":"^7.10.5","@babel/core":"^7.11.1","@babel/plugin-transform-runtime":"^7.11.0","@babel/preset-env":"^7.11.0","@babel/preset-typescript":"^7.10.4","@types/node":"^14.0.27","type-fest":"^0.16.0","typescript":"^3.9.7"},"_id":"@bconnorwhite/module@1.0.2","dist":{"shasum":"68842606e4c3eb650e2736fa630415ae10797f19","size":1427,"noattachment":false,"key":"/@bconnorwhite/module/-/@bconnorwhite/module-1.0.2.tgz","tarball":"http://registry.cnpm.dingdandao.com/@bconnorwhite/module/download/@bconnorwhite/module-1.0.2.tgz"},"maintainers":[{"name":"bconnorwhite","email":"connor.bcw@gmail.com"}],"_npmUser":{"name":"bconnorwhite","email":"connor.bcw@gmail.com"},"directories":{},"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/module_1.0.2_1597634515779_0.4722535217037407"},"_hasShrinkwrap":false,"publish_time":1597634515892,"_cnpm_publish_time":1597634515892},"1.0.1":{"name":"@bconnorwhite/module","version":"1.0.1","description":"Set commander version based on your module's package.json.","author":{"name":"Connor White"},"license":"MIT","keywords":["commander","version","read","package","json","module"],"repository":{"type":"git","url":"git+https://github.com/bconnorwhite/module.git"},"main":"./build/index.js","scripts":{"build":"babel ./src --out-dir ./build --config-file ./babel.config.json --extensions .ts --delete-dir-on-start && tsc --project ./tsconfig.json","prepublishOnly":"yarn build"},"dependencies":{"commander":"^6.0.0","read-json-safe":"^1.0.1"},"devDependencies":{"@babel/cli":"^7.10.5","@babel/core":"^7.11.1","@babel/plugin-transform-runtime":"^7.11.0","@babel/preset-env":"^7.11.0","@babel/preset-typescript":"^7.10.4","@types/node":"^14.0.27","type-fest":"^0.16.0","typescript":"^3.9.7"},"_id":"@bconnorwhite/module@1.0.1","dist":{"shasum":"05ef690b96db87d6384a76d500318ff66c0f7c44","size":1417,"noattachment":false,"key":"/@bconnorwhite/module/-/@bconnorwhite/module-1.0.1.tgz","tarball":"http://registry.cnpm.dingdandao.com/@bconnorwhite/module/download/@bconnorwhite/module-1.0.1.tgz"},"maintainers":[{"name":"bconnorwhite","email":"connor.bcw@gmail.com"}],"_npmUser":{"name":"bconnorwhite","email":"connor.bcw@gmail.com"},"directories":{},"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/module_1.0.1_1597633148113_0.24101366787842293"},"_hasShrinkwrap":false,"publish_time":1597633148234,"_cnpm_publish_time":1597633148234},"1.0.0":{"name":"@bconnorwhite/module","version":"1.0.0","description":"Set commander version based on your module's package.json.","author":{"name":"Connor White"},"license":"MIT","keywords":["commander","version","read","package","json","module"],"repository":{"type":"git","url":"git+https://github.com/bconnorwhite/module.git"},"main":"./build/index.js","scripts":{"build":"babel ./src --out-dir ./build --config-file ./babel.config.json --extensions .ts --delete-dir-on-start && tsc --project ./tsconfig.json","prepublishOnly":"yarn build"},"dependencies":{"commander":"^6.0.0","read-json-safe":"^1.0.1"},"devDependencies":{"@babel/cli":"^7.10.5","@babel/core":"^7.11.1","@babel/plugin-transform-runtime":"^7.11.0","@babel/preset-env":"^7.11.0","@babel/preset-typescript":"^7.10.4","@types/node":"^14.0.27","type-fest":"^0.16.0","typescript":"^3.9.7"},"_id":"@bconnorwhite/module@1.0.0","dist":{"shasum":"bf8c100d56db320a3d09f7ce46c751ee5cde25eb","size":1676,"noattachment":false,"key":"/@bconnorwhite/module/-/@bconnorwhite/module-1.0.0.tgz","tarball":"http://registry.cnpm.dingdandao.com/@bconnorwhite/module/download/@bconnorwhite/module-1.0.0.tgz"},"maintainers":[{"name":"bconnorwhite","email":"connor.bcw@gmail.com"}],"_npmUser":{"name":"bconnorwhite","email":"connor.bcw@gmail.com"},"directories":{},"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/module_1.0.0_1597632913263_0.17225177336517916"},"_hasShrinkwrap":false,"publish_time":1597632913409,"_cnpm_publish_time":1597632913409}},"readme":"<div align=\"center\">\n  <h1>@bconnorwhite/module</h1>\n  <a href=\"https://npmjs.com/package/@bconnorwhite/module\">\n    <img alt=\"npm\" src=\"https://img.shields.io/npm/v/@bconnorwhite/module.svg\">\n  </a>\n  <a href=\"https://github.com/bconnorwhite/module\">\n    <img alt=\"typescript\" src=\"https://img.shields.io/github/languages/top/bconnorwhite/module.svg\">\n  </a>\n  <a href=\"https://github.com/bconnorwhite/module\">\n    <img alt=\"GitHub stars\" src=\"https://img.shields.io/github/stars/bconnorwhite/module?label=Stars%20Appreciated%21&style=social\">\n  </a>\n  <a href=\"https://twitter.com/bconnorwhite\">\n    <img alt=\"Twitter Follow\" src=\"https://img.shields.io/twitter/follow/bconnorwhite.svg?label=%40bconnorwhite&style=social\">\n  </a>\n</div>\n\n<br />\n\n> Read your module's package.json without importing it.\n\nWhy not just import your package.json? Importing your package.json can [break your project's structure](https://stackoverflow.com/questions/55753163/package-json-is-not-under-rootdir/61467483#61467483) when using TypeScript if package.json is outside of your source folder.\n\n## Installation\n\n```bash\nyarn add @bconnorwhite/module\n```\n\n```bash\nnpm install @bconnorwhite/module\n```\n\n## API\n\n```ts\nimport {\n  PackageJSON,\n  getPackageJSON,\n  getPackageJSONSync,\n  getVersion,\n  getVersionSync\n} from \"@bconnorwhite/module\";\n\nfunction getPackageJSON(dirname: string): Promise<PackageJSON | undefined>;\n\nfunction getPackageJSONSync(dirname: string): PackageJSON | undefined;\n\nfunction getVersion(dirname: string): Promise<string | undefined>;\n\nfunction getVersionSync(dirname: string): string | undefined;\n```\n\n<br />\n\n<h2>Dependencies<img align=\"right\" alt=\"dependencies\" src=\"https://img.shields.io/david/bconnorwhite/module.svg\"></h2>\n\n- [find-up](https://npmjs.com/package/find-up): Find a file or directory by walking up parent directories\n- [read-json-safe](https://www.npmjs.com/package/read-json-safe): Read objects from JSON files without try catch.\n- [types-pkg-json](https://www.npmjs.com/package/types-pkg-json): Type checking for package.json\n\n<br />\n\n<h2>Dev Dependencies<img align=\"right\" alt=\"David\" src=\"https://img.shields.io/david/dev/bconnorwhite/module.svg\"></h2>\n\n- [@bconnorwhite/bob](https://www.npmjs.com/package/@bconnorwhite/bob): Bob is a toolkit for TypeScript projects\n- [@types/node](https://www.npmjs.com/package/@types/node): TypeScript definitions for Node.js\n\n<br />\n\n<h2>License <img align=\"right\" alt=\"license\" src=\"https://img.shields.io/npm/l/@bconnorwhite/module.svg\"></h2>\n\n[MIT](https://opensource.org/licenses/MIT)\n\n<br />\n\n## Related Packages\n\n- [@bconnorwhite/package](https://www.npmjs.com/package/@bconnorwhite/package): A utility for reading package.json of a project, and forming paths relative to it.\n","_attachments":{},"homepage":"https://connorwhite.org/github/module","license":"MIT"}