{"name":"babel-plugin-dev-expression","version":"0.1.0","description":"A mirror of Facebook's dev-expression Babel plugin","main":"dev-expression.js","repository":{"type":"git","url":"git+https://github.com/4Catalyzer/babel-plugin-dev-expression.git"},"keywords":["facebook","react","babel","dev-expression"],"author":{"name":"Jimmy Jia"},"license":"BSD-3-Clause","bugs":{"url":"https://github.com/4Catalyzer/babel-plugin-dev-expression/issues"},"homepage":"https://github.com/4Catalyzer/babel-plugin-dev-expression#readme","gitHead":"6f97494a999a15b6e9ed899febfca435294f72ef","_id":"babel-plugin-dev-expression@0.1.0","scripts":{},"_shasum":"43119f461eebf01d6e3f18ee40726cd5147f52ca","_from":".","_npmVersion":"2.14.8","_nodeVersion":"4.2.1","_npmUser":{"name":"taion","email":"tesrin@gmail.com"},"dist":{"shasum":"43119f461eebf01d6e3f18ee40726cd5147f52ca","tarball":"http://registry-npm.ywwl.com/babel-plugin-dev-expression/download/babel-plugin-dev-expression-0.1.0.tgz","integrity":"sha512-9IKZsJCh11VHh2idsFYEHMLDTgJxCrKPVAklauXQ2+9WHoKfcMTN7ealDLYgUGJKmXJ3HXKKyupgLmTtZt+CJA==","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEQCIF7riJ+bn+zhiyQ6YbJqiSeQ+QJKVogyXzSQfzhv4MkfAiA2I6jH3qVe/+20mnY44aSX3ua05UEK3g96jUkSWYz7lw=="}],"size":4705,"noattachment":false,"key":"/babel-plugin-dev-expression/-/babel-plugin-dev-expression-0.1.0.tgz"},"maintainers":[{"name":"taion","email":"tesrin@gmail.com"}],"directories":{},"readme":"# babel-plugin-dev-expression [![npm version](https://badge.fury.io/js/babel-plugin-dev-expression.svg)](https://badge.fury.io/js/babel-plugin-dev-expression)\n\nA mirror of Facebook's dev-expression Babel plugin.\n\nThis plugin reduces or eliminates development checks from production code.\n\n## `__DEV__`\n\nReplaces\n\n```js\n__DEV__\n```\n\nwith\n\n```js\nprocess.env.NODE_ENV !== 'production'\n```\n\n**Note:** The `dev-expression` transform does not run when `NODE_ENV` is `test`. As such, if you use `__DEV__`, you will need to define it as a global constant in your test environment.\n\n## `invariant`\n\nReplaces\n\n```js\ninvariant(condition, argument, argument);\n```\n\nwith\n\n```js\nif (!condition) {\n  if (\"production\" !== process.env.NODE_ENV) {\n    invariant(false, argument, argument);\n  } else {\n    invariant(false);\n  }\n}\n```\n\nRecommended for use with https://github.com/zertosh/invariant or smaller https://github.com/alexreardon/tiny-invariant.\n\n## `warning`\n\nReplaces\n\n```js\nwarning(condition, argument, argument);\n```\n\nwith\n\n```js\nif (\"production\" !== process.env.NODE_ENV) {\n  warning(condition, argument, argument);\n}\n```\n\nRecommended for use with https://github.com/r3dm/warning or smaller https://github.com/alexreardon/tiny-warning.\n","publish_time":1446493090192,"_cnpm_publish_time":1446493090192,"dist-tags":{"latest":"0.2.3"}}