{"_id":"@6thquake/react-properties","_rev":"2-8c8d8db00ef911c3685937e4c8829014","name":"@6thquake/react-properties","dist-tags":{"latest":"0.1.0"},"versions":{"0.1.0":{"name":"@6thquake/react-properties","version":"0.1.0","private":false,"license":"MIT","main":"src/index.js","files":["src/*"],"keywords":["properties","env","json","webpack"],"description":"Loads multiple environments, and adds support for automatically reading configuration files for the three pre-defined environments: development, test, and production.","dependencies":{},"scripts":{"deploy":"npm publish --tag latest","test:test":"cross-env NODE_ENV=test node test/test.js","test:dev":"cross-env NODE_ENV=development node test/test.js","test":"cross-env NODE_ENV=production node test/test.js","lint":"eslint . --cache && echo \"eslint: no lint errors\"","prettier":"find . -name \"*.js\" -o -name \"*.d.ts\" -o -name \"*.tsx\" | grep -v -f .eslintignore | xargs prettier --write","spellcheck":"eslint . --config .eslintrc.spellcheck.js && echo \"eslint: no lint errors\""},"devDependencies":{"cross-env":"^5.2.0","eslint":"~4.19.1","eslint-config-airbnb":"^17.0.0","eslint-import-resolver-webpack":"^0.10.1","eslint-plugin-babel":"^5.1.0","eslint-plugin-flowtype":"^2.50.0","eslint-plugin-import":"^2.13.0","eslint-plugin-prettier":"^2.6.2","eslint-plugin-spellcheck":"^0.0.10","prettier":"^1.14.2"},"engines":{"node":"^6.10.2 || ^8.9.4 || >=9.10.0"},"gitHead":"8daa6cd053b24330f0a2fd7b15ad5f0eb942f909","_id":"@6thquake/react-properties@0.1.0","_npmVersion":"5.6.0","_nodeVersion":"8.9.4","_npmUser":{"name":"lico","email":"lico.atom@gmail.com"},"dist":{"integrity":"sha512-FWOCNQ2pgv8/dr6RK7kv1uhB/F11M92zW0mSDJM18fCVShOAOw9fsssD0Y+DkDeSHAoVvOsQ+EwxHiNC/vEF7g==","shasum":"01acb4491f9c9754e99288b1b35badf95a706988","tarball":"https://registry.npmjs.org/@6thquake/react-properties/-/react-properties-0.1.0.tgz","fileCount":9,"unpackedSize":25245,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.4\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJbcVqjCRA9TVsSAnZWagAABlkP/3wYfLCnb4/xOyljhe53\n/uvt4nsjsRnNVXF4Ch+5PQhFeQiN5khfOcScaGUj9rcZYbJrU4iR3jnAnVPi\norvwMixSsUsZEaxrCvZEJB4QxczNreQCWgOgcQN56Nw2bOB4Xpazw4mysvhe\n1R4qwZdnnWBsGvWgam37m1gkCr/+Qy/p9ku/BqezRFLr1/qLpNxx/kkG/ldk\nG++pT4Qd/P5GwUzIAFySBFkvkMF6kAyRZB16VwDv2Sto0ZDyWLyHP2I9Ph4j\nhqS5CrPVMwz/jPHnraGwkedDVMtOMBKiXMTMm1yk97owwHIUnojOVgGpyJyW\nVOSSzHQYAHUdn7L54l09YfmXslVt2QoIBIZYN9j3H79xGQUZdugrEm6ixo+1\nPFSeS33+rXPENYyFdgAyO0oruHdWaR/NwMCHjWPhp0eWA62m3caUu5UVJcby\nZWvHSOdzCXp9N7eEdEoXiDlvIT8gGiuJmDSX0XX/W1E5+pPu79xtRxIGwT4f\nhuCz1ZU21nVxmDLb54eep70ew0MFUAtnmGqB8+0xRto1+PsH3+UQ0oXwLp9B\nRE/EWUYnPeoHvjKeqwmGUFW19Vj1G6eOh/QsLkDWKy/Yc/rEt3xDZ2hsiQrB\nbvc7J/f7U2ERkAOjJ4nrp6+KdxUFvpCm+FmP/YluGr8NMOoUJwtjCwjXsHOa\nmoFR\r\n=dJrh\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEQCIB2UJeUXDx2qR33DonXR4eWlEC3NNiCPs5nhgS93IpmoAiBsiJzqvJIPOdPEUFdOhq24cJ92BBNh2akcLX4NGrJCSw=="}]},"maintainers":[{"name":"lico","email":"lico.atom@gmail.com"}],"directories":{},"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/react-properties_0.1.0_1534155426847_0.023005117572288958"},"_hasShrinkwrap":false}},"time":{"created":"2018-08-13T10:17:06.792Z","0.1.0":"2018-08-13T10:17:06.966Z","modified":"2022-04-04T10:49:00.450Z"},"maintainers":[{"email":"1182025989@qq.com","name":"chaos233"},{"email":"lico.atom@gmail.com","name":"lico"}],"description":"Loads multiple environments, and adds support for automatically reading configuration files for the three pre-defined environments: development, test, and production.","keywords":["properties","env","json","webpack"],"license":"MIT","readme":"<p align=\"center\">\n  <a href=\"/\" rel=\"noopener\" target=\"_blank\"><img width=\"20\" src=\"/public/logo.png\" alt=\"logo\"></a></p>\n</p>\n\n<h1 align=\"center\">react-properties</h1>\n\n\n## Installation\n\nThis module is distributed via npm, and the source code is available on github.com too.\n\n**npm**\n```sh\n$ npm install @6thquake/react-properties\n```\n\n**yarn**\n```sh\n$ yarn add @6thquake/react-properties\n```\n\n## Documentation\n> This module adds built-in support for a configuration file corresponding to each of these: .env.development, .env.test, and .env.production. The values from these files have higher priority than the values in .env. Each file (including the default file) supports another layer of overrides by adding .local to the end. The full order of precedence is (highest first):\n```\n.env.{environment}.local\n.env.{environment}\n.env.local\n.env\nlocal.json\npackage.json\n```\nThose top 4 hidden files follows Java .properties specification, ini sections;\n\nPlease Check out our [documentation website](/) for more information.\n\n## Examples\n\n* if you have a configuration file named **.env.development**:\n\n```\nHTTPS=false\nPORT=8080\n\n[proxy]\n/api.target=/\n/api.headers={}\n/api.changeOrigin=true\n/api.secure=false\n/api.proxyTimeout=6000\n/websocket.target=/\n/websocket.headers={}\n/websocket.changeOrigin=true\n/websocket.secure=false\n/websocket.ws=true\n```\n\n* **.env** file also supported at the root path of you project:\n```\nPORT=8888\n```\n\n* and the **package.json** is:\n```\n{\n\t\"name\": \"test\",\n\t\"dependencies\": {\n\t\t\"react-properties\": \"^0.1.0\"\n\t}\n}\n```\n\nin your node project:\n\n```javascript\nconst Properties = require('@6thquake/react-properties');\nconst properties = Properties.load(process.pwd());\n```\n\nif you run with \"NODE_ENV=development\", all the configuration parameters will be:\n```\n{\n\t\"HTTPS\": false,\n\t\"PORT\": 8888,\n\t\"name\": \"test\",\n\t\"dependencies\": {\n\t\t\"react-properties\": \"^0.1.0\"\n\t}\n\t\"proxy\":{\n\t\t\"/api\": {\n\t\t\t\"target\": \"/\",\n\t\t\t\"headers\": {},\n\t\t\t\"changeOrigin\": true,\n\t\t\t\"secure\": false,\n\t\t\t\"proxyTimeout\": 6000\n\n\t\t},\n\t\t\"/websocket\": {\n\t\t\t\"target\": \"/\",\n\t\t\t\"headers\": {},\n\t\t\t\"changeOrigin\": true,\n\t\t\t\"secure\": false,\n\t\t\t\"ws\": true\n\t\t}\n\t}\n}\n```\n\n## Contributing\n\nWe'd greatly appreciate any [contribution](/CONTRIBUTING.md) you make.)\n\n## Changelog\n\nRecently Updated?\nPlease read the [changelog](/CHANGELOG.md).\n\n## Roadmap\n\nThe future plans and high priority features and enhancements can be found in the [ROADMAP.md](/ROADMAP.md) file.\n\n## License\n\nThis project is licensed under the terms of the\n[MIT license](/LICENSE).\n","readmeFilename":"README.md"}