{"_id":"browser-or-node","_rev":"3794408","name":"browser-or-node","description":"Check in which environment the code is running - browser/node.js/webworker/jsdom/deno","dist-tags":{"latest":"3.0.0"},"maintainers":[{"name":"flexdinesh","email":""}],"time":{"modified":"2025-06-05T10:28:45.000Z","created":"2018-01-24T18:42:24.814Z","3.0.0":"2024-04-18T00:23:20.553Z","3.0.0-pre.0":"2023-11-19T03:28:46.166Z","2.1.1":"2022-12-01T23:00:54.407Z","2.1.0":"2022-11-30T23:35:59.033Z","2.0.0":"2021-11-12T23:09:36.205Z","1.3.0":"2020-06-25T04:01:25.423Z","1.2.1":"2019-04-14T06:21:07.830Z","1.1.0":"2018-07-29T01:54:42.812Z","1.0.2":"2018-01-25T03:53:00.708Z","1.0.1":"2018-01-24T18:50:56.938Z","1.0.0":"2018-01-24T18:42:24.814Z"},"users":{},"repository":{"type":"git","url":"git+https://github.com/flexdinesh/browser-or-node.git"},"versions":{"3.0.0":{"name":"browser-or-node","version":"3.0.0","description":"Check in which environment the code is running - browser/node.js/webworker/jsdom/deno","main":"./dist/index.js","module":"./dist/index.mjs","types":"./dist/index.d.ts","exports":{".":{"require":"./dist/index.js","import":"./dist/index.mjs","types":"./dist/index.d.ts"}},"scripts":{"build":"tsup","prepublishOnly":"npm run build"},"repository":{"type":"git","url":"git+https://github.com/flexdinesh/browser-or-node.git"},"keywords":["npm","browser","node","is browser","is node","is browser node"],"license":"MIT","homepage":"https://github.com/flexdinesh/browser-or-node#readme","devDependencies":{"prettier":"3.1.0","tsup":"^7.3.0","typescript":"^5.2.2"},"gitHead":"842874d6f302ccf3efa0e85d7e8741a476ddf1f0","bugs":{"url":"https://github.com/flexdinesh/browser-or-node/issues"},"_id":"browser-or-node@3.0.0","_nodeVersion":"18.17.1","_npmVersion":"9.6.7","dist":{"shasum":"2b11335570b28887e0bf5cd857f2e8062c6ae293","size":2795,"noattachment":false,"key":"/browser-or-node/-/browser-or-node-3.0.0.tgz","tarball":"http://registry.cnpm.dingdandao.com/browser-or-node/download/browser-or-node-3.0.0.tgz"},"_npmUser":{"name":"flexdinesh","email":"flexdinesh@gmail.com"},"directories":{},"maintainers":[{"name":"flexdinesh","email":""}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/browser-or-node_3.0.0_1713399800359_0.830592477959788"},"_hasShrinkwrap":false,"_cnpmcore_publish_time":"2024-04-18T00:23:20.553Z","publish_time":1713399800553,"_source_registry_name":"default","_cnpm_publish_time":1713399800553},"3.0.0-pre.0":{"name":"browser-or-node","version":"3.0.0-pre.0","description":"Check in which environment the code is running - browser/node.js/webworker/jsdom/deno","main":"./dist/index.js","module":"./dist/index.mjs","types":"./dist/index.d.ts","exports":{".":{"require":"./dist/index.js","import":"./dist/index.mjs","types":"./dist/index.d.ts"}},"scripts":{"build":"tsup","prepublishOnly":"npm run build"},"repository":{"type":"git","url":"git+https://github.com/flexdinesh/browser-or-node.git"},"keywords":["npm","browser","node","is browser","is node","is browser node"],"license":"MIT","homepage":"https://github.com/flexdinesh/browser-or-node#readme","devDependencies":{"prettier":"3.1.0","tsup":"^7.3.0","typescript":"^5.2.2"},"gitHead":"7499b1184e630e4ba44ce0f5706588b762acd889","bugs":{"url":"https://github.com/flexdinesh/browser-or-node/issues"},"_id":"browser-or-node@3.0.0-pre.0","_nodeVersion":"18.17.1","_npmVersion":"9.6.7","dist":{"shasum":"e95f81b604bd83c6307669f70feebee458d738f6","size":2610,"noattachment":false,"key":"/browser-or-node/-/browser-or-node-3.0.0-pre.0.tgz","tarball":"http://registry.cnpm.dingdandao.com/browser-or-node/download/browser-or-node-3.0.0-pre.0.tgz"},"_npmUser":{"name":"flexdinesh","email":"flexdinesh@gmail.com"},"directories":{},"maintainers":[{"name":"flexdinesh","email":""}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/browser-or-node_3.0.0-pre.0_1700364525906_0.09436081443268529"},"_hasShrinkwrap":false,"_cnpmcore_publish_time":"2023-11-19T03:28:46.166Z","publish_time":1700364526166,"_source_registry_name":"default","_cnpm_publish_time":1700364526166},"2.1.1":{"name":"browser-or-node","version":"2.1.1","description":"Check where the code is running in the browser or node.js","main":"./lib/index.js","types":"./lib/index.d.ts","scripts":{"clean":"rimraf lib","test":"npm run cover","test:only":"cross-env BABEL_ENV=commonjs mocha --require babel-core/register --recursive","test:watch":"npm test -- --watch","test:examples":"node examples/","cover":"cross-env BABEL_ENV=commonjs istanbul cover node_modules/mocha/bin/_mocha -- --require babel-core/register --recursive","lint":"eslint src","build":"cross-env BABEL_ENV=commonjs babel src --out-dir lib --copy-files","prepublish":"npm run clean && npm run lint && npm run test && npm run build"},"repository":{"type":"git","url":"git+https://github.com/flexdinesh/browser-or-node.git"},"keywords":["npm","browser","node","is browser","is node","is browser node"],"author":{"name":"Dineshkumar Pandiyan","email":"flexdinesh@gmail.com"},"contributors":[{"name":"Daniel Wang","email":"daniel.liberated@gmail.com","url":"https://github.com/dan1wang/"}],"license":"MIT","bugs":{"url":"https://github.com/flexdinesh/browser-or-node/issues"},"homepage":"https://github.com/flexdinesh/browser-or-node#readme","devDependencies":{"babel":"^6.23.0","babel-cli":"^6.26.0","babel-eslint":"^10.1.0","babel-plugin-add-module-exports":"^1.0.2","babel-preset-es2015":"^6.24.1","babel-preset-stage-2":"^6.24.1","chai":"^4.2.0","cross-env":"^7.0.2","eslint":"^7.3.1","eslint-config-prettier":"^8.3.0","eslint-plugin-import":"^2.21.2","eslint-plugin-jsx-a11y":"^6.3.1","eslint-plugin-react":"^7.20.0","istanbul":"^1.0.0-alpha","mocha":"^8.0.1","rimraf":"^3.0.2"},"gitHead":"9875469e69b0dbc6a35e50b104495facf869bb4a","_id":"browser-or-node@2.1.1","_nodeVersion":"14.20.0","_npmVersion":"6.14.17","dist":{"shasum":"738790b3a86a8fc020193fa581273fbe65eaea0f","size":2656,"noattachment":false,"key":"/browser-or-node/-/browser-or-node-2.1.1.tgz","tarball":"http://registry.cnpm.dingdandao.com/browser-or-node/download/browser-or-node-2.1.1.tgz"},"_npmUser":{"name":"flexdinesh","email":"flexdinesh@gmail.com"},"directories":{},"maintainers":[{"name":"flexdinesh","email":""}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/browser-or-node_2.1.1_1669935654223_0.9956188040876126"},"_hasShrinkwrap":false,"_cnpmcore_publish_time":"2022-12-01T23:00:58.185Z","publish_time":1669935654407,"_cnpm_publish_time":1669935654407},"2.1.0":{"name":"browser-or-node","version":"2.1.0","description":"Check where the code is running in the browser or node.js","main":"./lib/index.js","types":"./lib/index.d.ts","scripts":{"clean":"rimraf lib","test":"npm run cover","test:only":"cross-env BABEL_ENV=commonjs mocha --require babel-core/register --recursive","test:watch":"npm test -- --watch","test:examples":"node examples/","cover":"cross-env BABEL_ENV=commonjs istanbul cover node_modules/mocha/bin/_mocha -- --require babel-core/register --recursive","lint":"eslint src","build":"cross-env BABEL_ENV=commonjs babel src --out-dir lib --copy-files","prepublish":"npm run clean && npm run lint && npm run test && npm run build"},"repository":{"type":"git","url":"git+https://github.com/flexdinesh/browser-or-node.git"},"keywords":["npm","browser","node","is browser","is node","is browser node"],"author":{"name":"Dineshkumar Pandiyan","email":"flexdinesh@gmail.com"},"contributors":[{"name":"Daniel Wang","email":"daniel.liberated@gmail.com","url":"https://github.com/dan1wang/"}],"license":"MIT","bugs":{"url":"https://github.com/flexdinesh/browser-or-node/issues"},"homepage":"https://github.com/flexdinesh/browser-or-node#readme","devDependencies":{"babel":"^6.23.0","babel-cli":"^6.26.0","babel-eslint":"^10.1.0","babel-plugin-add-module-exports":"^1.0.2","babel-preset-es2015":"^6.24.1","babel-preset-stage-2":"^6.24.1","chai":"^4.2.0","cross-env":"^7.0.2","eslint":"^7.3.1","eslint-config-prettier":"^8.3.0","eslint-plugin-import":"^2.21.2","eslint-plugin-jsx-a11y":"^6.3.1","eslint-plugin-react":"^7.20.0","istanbul":"^1.0.0-alpha","mocha":"^8.0.1","rimraf":"^3.0.2"},"gitHead":"12d24c99967ee64870abed07f448682851344367","_id":"browser-or-node@2.1.0","_nodeVersion":"16.17.0","_npmVersion":"8.15.0","dist":{"shasum":"7b9d59ba265bf21449fcac0e87319d866e70ce13","size":2312,"noattachment":false,"key":"/browser-or-node/-/browser-or-node-2.1.0.tgz","tarball":"http://registry.cnpm.dingdandao.com/browser-or-node/download/browser-or-node-2.1.0.tgz"},"_npmUser":{"name":"flexdinesh","email":"flexdinesh@gmail.com"},"directories":{},"maintainers":[{"name":"flexdinesh","email":""}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/browser-or-node_2.1.0_1669851358851_0.7926591586073295"},"_hasShrinkwrap":false,"_cnpmcore_publish_time":"2022-11-30T23:36:19.615Z","publish_time":1669851359033,"_cnpm_publish_time":1669851359033},"2.0.0":{"name":"browser-or-node","version":"2.0.0","description":"Check where the code is running in the browser or node.js","main":"./lib/index.js","types":"./lib/index.d.ts","scripts":{"clean":"rimraf lib","test":"npm run cover","test:only":"cross-env BABEL_ENV=commonjs mocha --require babel-core/register --recursive","test:watch":"npm test -- --watch","test:examples":"node examples/","cover":"cross-env BABEL_ENV=commonjs istanbul cover node_modules/mocha/bin/_mocha -- --require babel-core/register --recursive","lint":"eslint src","build":"cross-env BABEL_ENV=commonjs babel src --out-dir lib --copy-files","prepublish":"npm run clean && npm run lint && npm run test && npm run build"},"repository":{"type":"git","url":"git+https://github.com/flexdinesh/browser-or-node.git"},"keywords":["npm","browser","node","is browser","is node","is browser node"],"author":{"name":"Dineshkumar Pandiyan","email":"flexdinesh@gmail.com"},"contributors":[{"name":"Daniel Wang","email":"daniel.liberated@gmail.com","url":"https://github.com/dan1wang/"}],"license":"MIT","bugs":{"url":"https://github.com/flexdinesh/browser-or-node/issues"},"homepage":"https://github.com/flexdinesh/browser-or-node#readme","devDependencies":{"babel":"^6.23.0","babel-cli":"^6.26.0","babel-eslint":"^10.1.0","babel-plugin-add-module-exports":"^1.0.2","babel-preset-es2015":"^6.24.1","babel-preset-stage-2":"^6.24.1","chai":"^4.2.0","cross-env":"^7.0.2","eslint":"^7.3.1","eslint-config-prettier":"^8.3.0","eslint-plugin-import":"^2.21.2","eslint-plugin-jsx-a11y":"^6.3.1","eslint-plugin-react":"^7.20.0","istanbul":"^1.0.0-alpha","mocha":"^8.0.1","rimraf":"^3.0.2"},"gitHead":"ae67a84b7cdc65021a198b18f16c3bdbf4b480d8","_id":"browser-or-node@2.0.0","_nodeVersion":"16.9.0","_npmVersion":"7.21.1","dist":{"shasum":"808ea90282a670931cdc0ea98166538a50dd0d89","size":2606,"noattachment":false,"key":"/browser-or-node/-/browser-or-node-2.0.0.tgz","tarball":"http://registry.cnpm.dingdandao.com/browser-or-node/download/browser-or-node-2.0.0.tgz"},"_npmUser":{"name":"flexdinesh","email":"flexdinesh@gmail.com"},"directories":{},"maintainers":[{"name":"flexdinesh","email":""}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/browser-or-node_2.0.0_1636758576076_0.9288731609531589"},"_hasShrinkwrap":false,"publish_time":1636758576205,"_cnpm_publish_time":1636758576205,"_cnpmcore_publish_time":"2021-12-16T15:36:40.665Z"},"1.3.0":{"name":"browser-or-node","version":"1.3.0","description":"Check where the code is running in the browser or node.js","main":"./lib/index.js","scripts":{"clean":"rimraf lib","test":"npm run cover","test:only":"cross-env BABEL_ENV=commonjs mocha --require babel-core/register --recursive","test:watch":"npm test -- --watch","test:examples":"node examples/","cover":"cross-env BABEL_ENV=commonjs istanbul cover node_modules/mocha/bin/_mocha -- --require babel-core/register --recursive","lint":"eslint src","build":"cross-env BABEL_ENV=commonjs babel src --out-dir lib","prepublish":"npm run clean && npm run lint && npm run test && npm run build"},"repository":{"type":"git","url":"git+https://github.com/flexdinesh/browser-or-node.git"},"keywords":["npm","browser","node","is browser","is node","is browser node"],"author":{"name":"Dineshkumar Pandiyan","email":"flexdinesh@gmail.com"},"contributors":[{"name":"Daniel Wang","email":"daniel.liberated@gmail.com","url":"https://github.com/dan1wang/"}],"license":"MIT","bugs":{"url":"https://github.com/flexdinesh/browser-or-node/issues"},"homepage":"https://github.com/flexdinesh/browser-or-node#readme","devDependencies":{"babel":"^6.23.0","babel-cli":"^6.26.0","babel-eslint":"^10.1.0","babel-plugin-add-module-exports":"^1.0.2","babel-preset-es2015":"^6.24.1","babel-preset-stage-2":"^6.24.1","chai":"^4.2.0","cross-env":"^7.0.2","eslint":"^7.3.1","eslint-config-airbnb":"^18.2.0","eslint-plugin-import":"^2.21.2","eslint-plugin-jsx-a11y":"^6.3.1","eslint-plugin-react":"^7.20.0","istanbul":"^1.0.0-alpha","mocha":"^8.0.1","rimraf":"^3.0.2"},"gitHead":"545bf1649148fff3006127e0c8fea3d0bf488f1a","_id":"browser-or-node@1.3.0","_nodeVersion":"12.16.1","_npmVersion":"6.13.4","dist":{"shasum":"f2a4e8568f60263050a6714b2cc236bb976647a7","size":2533,"noattachment":false,"key":"/browser-or-node/-/browser-or-node-1.3.0.tgz","tarball":"http://registry.cnpm.dingdandao.com/browser-or-node/download/browser-or-node-1.3.0.tgz"},"maintainers":[{"name":"flexdinesh","email":""}],"_npmUser":{"name":"flexdinesh","email":"flexdinesh@gmail.com"},"directories":{},"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/browser-or-node_1.3.0_1593057685269_0.9747471110500745"},"_hasShrinkwrap":false,"publish_time":1593057685423,"_cnpm_publish_time":1593057685423,"_cnpmcore_publish_time":"2021-12-16T15:36:40.893Z"},"1.2.1":{"name":"browser-or-node","version":"1.2.1","description":"Check where the code is running in the browser or node.js","main":"./lib/index.js","scripts":{"clean":"rimraf lib","test":"npm run cover","test:only":"cross-env BABEL_ENV=commonjs mocha --require babel-core/register --recursive","test:watch":"npm test -- --watch","test:examples":"node examples/","cover":"cross-env BABEL_ENV=commonjs istanbul cover node_modules/mocha/bin/_mocha -- --require babel-core/register --recursive","lint":"eslint src test","build":"cross-env BABEL_ENV=commonjs babel src --out-dir lib","prepublish":"npm run clean && npm run lint && npm run test && npm run build"},"repository":{"type":"git","url":"git+https://github.com/flexdinesh/browser-or-node.git"},"keywords":["npm","browser","node","is browser","is node","is browser node"],"author":{"name":"Dineshkumar Pandiyan","email":"flexdinesh@gmail.com"},"contributors":[{"name":"Daniel Wang","email":"daniel.liberated@gmail.com","url":"https://github.com/dan1wang/"}],"license":"MIT","bugs":{"url":"https://github.com/flexdinesh/browser-or-node/issues"},"homepage":"https://github.com/flexdinesh/browser-or-node#readme","devDependencies":{"babel":"^6.23.0","babel-cli":"^6.26.0","babel-eslint":"^8.2.1","babel-plugin-add-module-exports":"^0.2.1","babel-preset-es2015":"^6.24.1","babel-preset-stage-2":"^6.24.1","chai":"^4.1.2","cross-env":"^5.1.3","eslint":"^4.16.0","eslint-config-airbnb":"^16.1.0","eslint-plugin-import":"^2.7.0","eslint-plugin-jsx-a11y":"^6.0.2","eslint-plugin-react":"^7.4.0","istanbul":"^1.0.0-alpha","mocha":"^5.0.0","rimraf":"^2.6.2"},"gitHead":"dd3970eabf095f22d710de485961e21e2c1c92fa","_id":"browser-or-node@1.2.1","_nodeVersion":"11.13.0","_npmVersion":"6.9.0","dist":{"shasum":"cd65172da6a7fd689c7a650d326bd2ad145419a7","size":2348,"noattachment":false,"key":"/browser-or-node/-/browser-or-node-1.2.1.tgz","tarball":"http://registry.cnpm.dingdandao.com/browser-or-node/download/browser-or-node-1.2.1.tgz"},"maintainers":[{"name":"flexdinesh","email":""}],"_npmUser":{"name":"flexdinesh","email":"flexdinesh@gmail.com"},"directories":{},"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/browser-or-node_1.2.1_1555222867700_0.7680553039717779"},"_hasShrinkwrap":false,"publish_time":1555222867830,"_cnpm_publish_time":1555222867830,"_cnpmcore_publish_time":"2021-12-16T15:36:41.092Z"},"1.1.0":{"name":"browser-or-node","version":"1.1.0","description":"Check where the code is running in the browser or node.js","main":"./lib/index.js","scripts":{"clean":"rimraf lib","test":"npm run cover","test:only":"cross-env BABEL_ENV=commonjs mocha --require babel-core/register --recursive","test:watch":"npm test -- --watch","test:examples":"node examples/","cover":"cross-env BABEL_ENV=commonjs istanbul cover node_modules/mocha/bin/_mocha -- --require babel-core/register --recursive","lint":"eslint src test","build":"cross-env BABEL_ENV=commonjs babel src --out-dir lib","prepublish":"npm run clean && npm run lint && npm run test && npm run build"},"files":["lib","src"],"repository":{"type":"git","url":"git+https://github.com/flexdinesh/browser-or-node.git"},"keywords":["npm","browser","node","is browser","is node","is browser node"],"author":{"name":"Dineshkumar Pandiyan","email":"flexdinesh@gmail.com"},"license":"MIT","bugs":{"url":"https://github.com/flexdinesh/browser-or-node/issues"},"homepage":"https://github.com/flexdinesh/browser-or-node#readme","devDependencies":{"babel":"^6.23.0","babel-cli":"^6.26.0","babel-eslint":"^8.2.1","babel-plugin-add-module-exports":"^0.2.1","babel-preset-es2015":"^6.24.1","babel-preset-stage-2":"^6.24.1","chai":"^4.1.2","cross-env":"^5.1.3","eslint":"^4.16.0","eslint-config-airbnb":"^16.1.0","eslint-plugin-import":"^2.7.0","eslint-plugin-jsx-a11y":"^6.0.2","eslint-plugin-react":"^7.4.0","istanbul":"^1.0.0-alpha","mocha":"^5.0.0","rimraf":"^2.6.2"},"gitHead":"5d90b7557fe6611df004a82a39cc196e79c207c0","_id":"browser-or-node@1.1.0","_npmVersion":"5.6.0","_nodeVersion":"8.11.3","_npmUser":{"name":"flexdinesh","email":"flexdinesh@gmail.com"},"dist":{"shasum":"e47e8d7701c42d83edab02abc1f6b532a4d6b66d","size":2132,"noattachment":false,"key":"/browser-or-node/-/browser-or-node-1.1.0.tgz","tarball":"http://registry.cnpm.dingdandao.com/browser-or-node/download/browser-or-node-1.1.0.tgz"},"maintainers":[{"name":"flexdinesh","email":""}],"directories":{},"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/browser-or-node_1.1.0_1532829282728_0.36418528800656524"},"_hasShrinkwrap":false,"publish_time":1532829282812,"_cnpm_publish_time":1532829282812,"_cnpmcore_publish_time":"2021-12-16T15:36:41.307Z"},"1.0.2":{"name":"browser-or-node","version":"1.0.2","description":"Check where the code is running in the browser or node.js","main":"./lib/index.js","scripts":{"clean":"rimraf lib","test":"npm run cover","test:only":"cross-env BABEL_ENV=commonjs mocha --require babel-core/register --recursive","test:watch":"npm test -- --watch","test:examples":"node examples/","cover":"cross-env BABEL_ENV=commonjs istanbul cover _mocha -- --require babel-core/register --recursive","lint":"eslint src test","build":"cross-env BABEL_ENV=commonjs babel src --out-dir lib","prepublish":"npm run clean && npm run lint && npm run test && npm run build"},"files":["lib","src"],"repository":{"type":"git","url":"git+https://github.com/flexdinesh/browser-or-node.git"},"keywords":["npm","browser","node","is browser","is node","is browser node"],"author":{"name":"Dineshkumar Pandiyan","email":"flexdinesh@gmail.com"},"license":"MIT","bugs":{"url":"https://github.com/flexdinesh/browser-or-node/issues"},"homepage":"https://github.com/flexdinesh/browser-or-node#readme","devDependencies":{"babel":"^6.23.0","babel-cli":"^6.26.0","babel-eslint":"^8.2.1","babel-plugin-add-module-exports":"^0.2.1","babel-preset-es2015":"^6.24.1","babel-preset-stage-2":"^6.24.1","chai":"^4.1.2","cross-env":"^5.1.3","eslint":"^4.16.0","eslint-config-airbnb":"^16.1.0","eslint-plugin-import":"^2.7.0","eslint-plugin-jsx-a11y":"^6.0.2","eslint-plugin-react":"^7.4.0","istanbul":"^1.0.0-alpha","mocha":"^5.0.0","rimraf":"^2.6.2"},"gitHead":"fc88f7a13d962e4b1a2fe31cb8d95e8dfc480502","_id":"browser-or-node@1.0.2","_npmVersion":"5.6.0","_nodeVersion":"9.4.0","_npmUser":{"name":"flexdinesh","email":"flexdinesh@gmail.com"},"maintainers":[{"name":"flexdinesh","email":""}],"dist":{"shasum":"d2053e61e7e774aa983fcab76b4ebc2cf6504a72","size":2110,"noattachment":false,"key":"/browser-or-node/-/browser-or-node-1.0.2.tgz","tarball":"http://registry.cnpm.dingdandao.com/browser-or-node/download/browser-or-node-1.0.2.tgz"},"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/browser-or-node-1.0.2.tgz_1516852379839_0.42830262589268386"},"directories":{},"publish_time":1516852380708,"_hasShrinkwrap":false,"_cnpm_publish_time":1516852380708,"_cnpmcore_publish_time":"2021-12-16T15:36:41.522Z"},"1.0.1":{"name":"browser-or-node","version":"1.0.1","description":"Check where the code is running in the browser or node.js","main":"./lib/index.js","scripts":{"clean":"rimraf lib","test":"npm run cover","test:only":"cross-env BABEL_ENV=commonjs mocha --require babel-core/register --recursive","test:watch":"npm test -- --watch","test:examples":"node examples/","cover":"cross-env BABEL_ENV=commonjs istanbul cover _mocha -- --require babel-core/register --recursive","lint":"eslint src test","build":"cross-env BABEL_ENV=commonjs babel src --out-dir lib","prepublish":"npm run clean && npm run lint && npm run test && npm run build"},"files":["lib","src"],"repository":{"type":"git","url":"git+https://github.com/flexdinesh/browser-or-node.git"},"keywords":["npm","module","node","javascript","package json","package.json","get package json"],"author":{"name":"Dineshkumar Pandiyan","email":"flexdinesh@gmail.com"},"license":"MIT","bugs":{"url":"https://github.com/flexdinesh/browser-or-node/issues"},"homepage":"https://github.com/flexdinesh/browser-or-node#readme","devDependencies":{"babel":"^6.23.0","babel-cli":"^6.26.0","babel-eslint":"^8.2.1","babel-plugin-add-module-exports":"^0.2.1","babel-preset-es2015":"^6.24.1","babel-preset-stage-2":"^6.24.1","chai":"^4.1.2","cross-env":"^5.1.3","eslint":"^4.16.0","eslint-config-airbnb":"^16.1.0","eslint-plugin-import":"^2.7.0","eslint-plugin-jsx-a11y":"^6.0.2","eslint-plugin-react":"^7.4.0","istanbul":"^1.0.0-alpha","mocha":"^5.0.0","rimraf":"^2.6.2"},"gitHead":"abe834c9634c869b90b6a010405671dd925617a6","_id":"browser-or-node@1.0.1","_npmVersion":"5.6.0","_nodeVersion":"9.4.0","_npmUser":{"name":"flexdinesh","email":"flexdinesh@gmail.com"},"maintainers":[{"name":"flexdinesh","email":""}],"dist":{"shasum":"caba6902d4e46c18cc40f5117ab54a593f805058","size":2090,"noattachment":false,"key":"/browser-or-node/-/browser-or-node-1.0.1.tgz","tarball":"http://registry.cnpm.dingdandao.com/browser-or-node/download/browser-or-node-1.0.1.tgz"},"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/browser-or-node-1.0.1.tgz_1516819856079_0.4700031748507172"},"directories":{},"publish_time":1516819856938,"_hasShrinkwrap":false,"_cnpm_publish_time":1516819856938,"_cnpmcore_publish_time":"2021-12-16T15:36:41.784Z"},"1.0.0":{"name":"browser-or-node","version":"1.0.0","description":"Check where the code is running in the browser or node.js","main":"./lib/index.js","scripts":{"clean":"rimraf lib","test":"npm run cover","test:only":"cross-env BABEL_ENV=commonjs mocha --require babel-core/register --recursive","test:watch":"npm test -- --watch","test:examples":"node examples/","cover":"cross-env BABEL_ENV=commonjs istanbul cover _mocha -- --require babel-core/register --recursive","lint":"eslint src test","build":"cross-env BABEL_ENV=commonjs babel src --out-dir lib","prepublish":"npm run clean && npm run lint && npm run test && npm run build"},"files":["lib","src"],"repository":{"type":"git","url":"git+https://github.com/flexdinesh/browser-or-node.git"},"keywords":["npm","module","node","javascript","package json","package.json","get package json"],"author":{"name":"Dineshkumar Pandiyan","email":"flexdinesh@gmail.com"},"license":"MIT","bugs":{"url":"https://github.com/flexdinesh/browser-or-node/issues"},"homepage":"https://github.com/flexdinesh/browser-or-node#readme","devDependencies":{"babel":"^6.23.0","babel-cli":"^6.26.0","babel-eslint":"^8.2.1","babel-plugin-add-module-exports":"^0.2.1","babel-preset-es2015":"^6.24.1","babel-preset-stage-2":"^6.24.1","chai":"^4.1.2","cross-env":"^5.1.3","eslint":"^4.16.0","eslint-config-airbnb":"^16.1.0","eslint-plugin-import":"^2.7.0","eslint-plugin-jsx-a11y":"^6.0.2","eslint-plugin-react":"^7.4.0","istanbul":"^1.0.0-alpha","mocha":"^5.0.0","rimraf":"^2.6.2"},"gitHead":"9f95ee24b225da655a967b2acc0c3cc7ec243548","_id":"browser-or-node@1.0.0","_npmVersion":"5.6.0","_nodeVersion":"9.4.0","_npmUser":{"name":"flexdinesh","email":"flexdinesh@gmail.com"},"maintainers":[{"name":"flexdinesh","email":""}],"dist":{"shasum":"0f4caf93764051b6508e853f3ab2b20f21e037d6","size":2154,"noattachment":false,"key":"/browser-or-node/-/browser-or-node-1.0.0.tgz","tarball":"http://registry.cnpm.dingdandao.com/browser-or-node/download/browser-or-node-1.0.0.tgz"},"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/browser-or-node-1.0.0.tgz_1516819343778_0.25287886755540967"},"directories":{},"publish_time":1516819344814,"_hasShrinkwrap":false,"_cnpm_publish_time":1516819344814,"_cnpmcore_publish_time":"2021-12-16T15:36:42.013Z"}},"readme":"# Browser or Node.js\n\n[![npm version](https://badge.fury.io/js/browser-or-node.svg)](https://www.npmjs.com/package/browser-or-node)\n[![License: MIT](https://img.shields.io/badge/License-MIT-blue.svg)](https://opensource.org/licenses/MIT)\n\nCheck in which environment the code is running - browser/node.js/webworker/jsdom/deno.\n\n\n\n> [!NOTE]\n> To help release v3.0.0, please try [v3.0.0-pre.0](https://github.com/flexdinesh/browser-or-node/releases/tag/3.0.0-pre.0) and let us know if you run into issues.\n\n## Install\n\n```\n$ npm install --save browser-or-node\n```\n\n## Usage\n\nImport the checks and use it in your code. Works with both ESM and CJS imports.\n\n```js\nimport * as jsEnv from \"browser-or-node\";\n// import { isBrowser, isNode, isWebWorker, isJsDom, isDeno, isBun } from \"browser-or-node\";\n// const jsEnv = require(\"browser-or-node\");\n\nif (jsEnv.isBrowser) {\n  // do browser only stuff\n}\n\nif (jsEnv.isNode) {\n  // do node.js only stuff\n}\n\nif (jsEnv.isWebWorker) {\n  // do web worker only stuff\n}\n\nif (jsEnv.isJsDom) {\n  // do jsdom only stuff\n}\n\nif (jsEnv.isDeno) {\n  // do deno only stuff\n}\n\nif (jsEnv.isBun) {\n  // do bun only stuff\n}\n```\n\n## License\n\nMIT © Dinesh Pandiyan\n","_attachments":{},"homepage":"https://github.com/flexdinesh/browser-or-node#readme","bugs":{"url":"https://github.com/flexdinesh/browser-or-node/issues"},"license":"MIT"}