|
1 | 1 | { |
2 | 2 | "name": "react-atomic-atom", |
3 | | - "version": "1.0.18", |
| 3 | + "version": "2.0.0", |
4 | 4 | "description": "Atomic design in React (atoms)", |
5 | | - "main": "./build/src/index.js", |
| 5 | + "main": "./build/cjs/src/index.js", |
| 6 | + "module": "./build/es/src/index.js", |
6 | 7 | "repository": "react-atomic/react-atomic-atom", |
7 | 8 | "keywords": [ |
8 | 9 | "reactjs" |
9 | 10 | ], |
10 | 11 | "author": "Hill <hill@kimo.com>", |
11 | 12 | "license": "MIT", |
| 13 | + "dependencies": { |
| 14 | + "reshow-runtime": "*" |
| 15 | + }, |
12 | 16 | "devDependencies": { |
13 | | - "babel-cli": "^6.x", |
14 | | - "babel-core": "^6.x", |
15 | | - "babel-plugin-add-module-exports": "^0.1.2", |
16 | | - "babel-preset-env": "*", |
17 | | - "babel-preset-react": "^6.x", |
18 | | - "babel-preset-stage-0": "^6.x", |
| 17 | + "@babel/cli": "^7.x", |
| 18 | + "@babel/core": "^7.x", |
| 19 | + "@babel/plugin-proposal-class-properties": "*", |
| 20 | + "@babel/plugin-proposal-export-default-from": "*", |
| 21 | + "@babel/plugin-proposal-object-rest-spread": "*", |
| 22 | + "@babel/plugin-syntax-dynamic-import": "*", |
| 23 | + "@babel/plugin-transform-object-assign": "*", |
| 24 | + "@babel/plugin-transform-react-constant-elements": "*", |
| 25 | + "@babel/preset-env": "*", |
| 26 | + "@babel/preset-react": "*", |
| 27 | + "babel-plugin-add-module-exports": "*", |
| 28 | + "babel-plugin-dynamic-import-node": "*", |
| 29 | + "babel-plugin-reshow-transform-runtime": "*", |
| 30 | + "babel-plugin-transform-react-pure-class-to-function": "*", |
| 31 | + "babel-plugin-transform-react-remove-prop-types": "*", |
19 | 32 | "react": "^16.x" |
20 | 33 | }, |
21 | 34 | "scripts": { |
22 | | - "build": "rm -rf build && babel ui --out-dir build/ui && babel src --out-dir build/src", |
23 | | - "prepublish": "npm run build" |
| 35 | + "clean": "find ./build -name '*.*' | xargs rm -rf", |
| 36 | + "build:cjs": "BABEL_ENV=build babel src -d build/cjs/src && BABEL_ENV=build babel ui -d build/cjs/ui", |
| 37 | + "build:es": "BABEL_ENV=es babel src -d build/es/src && BABEL_ENV=es babel ui -d build/es/ui", |
| 38 | + "build": "npm run clean && npm run build:cjs && npm run build:es", |
| 39 | + "prepublishOnly": "npm run build" |
24 | 40 | }, |
25 | 41 | "files": [ |
26 | 42 | "build", |
|
0 commit comments