Skip to content
This repository was archived by the owner on Apr 1, 2023. It is now read-only.

Dependency cleanup #122

Closed
wants to merge 7 commits into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
29 changes: 27 additions & 2 deletions template/default/.babelrc
Original file line number Diff line number Diff line change
Expand Up @@ -5,5 +5,30 @@
}],
"@babel/preset-react"
],
"plugins": ["@babel/plugin-proposal-class-properties"]
}
"exclude": "node_modules/**",
"plugins": [
// Stage 0
"@babel/plugin-proposal-function-bind",

// Stage 1
"@babel/plugin-proposal-export-default-from",
"@babel/plugin-proposal-logical-assignment-operators",
["@babel/plugin-proposal-optional-chaining", { "loose": false }],
["@babel/plugin-proposal-pipeline-operator", { "proposal": "minimal" }],
["@babel/plugin-proposal-nullish-coalescing-operator", { "loose": false }],
"@babel/plugin-proposal-do-expressions",

// Stage 2
["@babel/plugin-proposal-decorators", { "legacy": true }],
"@babel/plugin-proposal-function-sent",
"@babel/plugin-proposal-export-namespace-from",
"@babel/plugin-proposal-numeric-separator",
"@babel/plugin-proposal-throw-expressions",

// Stage 3
"@babel/plugin-syntax-dynamic-import",
"@babel/plugin-syntax-import-meta",
["@babel/plugin-proposal-class-properties", { "loose": false }],
"@babel/plugin-proposal-json-strings"
]
}
13 changes: 9 additions & 4 deletions template/default/example/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -5,16 +5,21 @@
"license": "MIT",
"private": true,
"dependencies": {
"prop-types": "^15.6.2",
"react": "^16.4.1",
"react-dom": "^16.4.1",
"react-scripts": "^1.1.4",
"react-scripts": "^2.1.3",
"{{name}}": "{{#if yarn}}link:..{{else}}file:..{{/if}}"
},
"scripts": {
"start": "react-scripts start",
"build": "react-scripts build",
"test": "react-scripts test --env=jsdom",
"test": "react-scripts test",
"eject": "react-scripts eject"
}
},
"browserslist": [
">0.2%",
"not dead",
"not ie <= 11",
"not op_mini all"
]
}
60 changes: 30 additions & 30 deletions template/default/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -13,22 +13,19 @@
"npm": ">=5"
},
"scripts": {
"test": "cross-env CI=1 react-scripts test --env=jsdom",
"test:watch": "react-scripts test --env=jsdom",
"test": "cross-env CI=1 react-scripts test",
"test:watch": "react-scripts test",
"build": "rollup -c",
"start": "rollup -c -w",
"prepare": "{{manager}} run build",
"predeploy": "cd example && {{manager}} install && {{manager}} run build",
"deploy": "gh-pages -d example/build"
},
"peerDependencies": {
"prop-types": "^15.5.4",
"react": "^15.0.0 || ^16.0.0",
"react-dom": "^15.0.0 || ^16.0.0"
"react": "^15.0.0 || ^16.0.0"
},
"devDependencies": {
"@babel/core": "^7.0.0",
"@babel/plugin-external-helpers": "^7.0.0",
"@babel/core": "^7.2.2",
"@babel/plugin-proposal-class-properties": "^7.0.0",
"@babel/plugin-proposal-decorators": "^7.0.0",
"@babel/plugin-proposal-do-expressions": "^7.0.0",
Expand All @@ -45,32 +42,35 @@
"@babel/plugin-proposal-throw-expressions": "^7.0.0",
"@babel/plugin-syntax-dynamic-import": "^7.0.0",
"@babel/plugin-syntax-import-meta": "^7.0.0",
"@babel/preset-env": "^7.0.0",
"@babel/preset-env": "^7.3.0",
"@babel/preset-react": "^7.0.0",
"@svgr/rollup": "^2.4.1",
"babel-eslint": "^10.0.1",
"cross-env": "^5.1.4",
"eslint": "^5.0.1",
"eslint-config-standard": "^11.0.0",
"eslint-config-standard-react": "^6.0.0",
"eslint-plugin-import": "^2.13.0",
"eslint-plugin-node": "^7.0.1",
"eslint-plugin-promise": "^4.0.0",
"eslint-plugin-react": "^7.10.0",
"eslint-plugin-standard": "^3.1.0",
"gh-pages": "^1.2.0",
"react": "^16.4.1",
"react-dom": "^16.4.1",
"react-scripts": "^1.1.4",
"rollup": "^0.64.1",
"rollup-plugin-babel": "^4.0.1",
"rollup-plugin-commonjs": "^9.1.3",
"rollup-plugin-node-resolve": "^3.3.0",
"@svgr/rollup": "^4.1.0",
"babel-eslint": "9.0.0",
"cross-env": "^5.2.0",
"eslint": "5.6.0",
"eslint-config-standard": "^12.0.0",
"eslint-config-standard-react": "^7.0.2",
"eslint-import-resolver-node": "^0.3.2",
"eslint-plugin-import": "^2.14.0",
"eslint-plugin-node": "^8.0.1",
"eslint-plugin-promise": "^4.0.1",
"eslint-plugin-react": "^7.12.4",
"eslint-plugin-standard": "^4.0.0",
"gh-pages": "^2.0.1",
"react": "^16.7.0",
"react-scripts": "^2.1.3",
"rollup": "^1.1.2",
"rollup-plugin-babel": "^4.3.2",
"rollup-plugin-commonjs": "^9.2.0",
"rollup-plugin-node-resolve": "^4.0.0",
"rollup-plugin-peer-deps-external": "^2.2.0",
"rollup-plugin-postcss": "^1.6.2",
"rollup-plugin-url": "^1.4.0"
"rollup-plugin-postcss": "^1.6.3",
"rollup-plugin-url": "^2.1.0"
},
"files": [
"dist"
]
],
"dependencies": {
"prop-types": "^15.6.2"
}

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Could you move this up before peerDependencies so it's more noticeable?

}
5 changes: 1 addition & 4 deletions template/default/rollup.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -29,10 +29,7 @@ export default {
}),
url({ exclude: ['**/*.svg'] }),
svgr(),
babel({
exclude: 'node_modules/**',
plugins: [ '@babel/external-helpers' ]
}),
babel(),
resolve(),
commonjs()
]
Expand Down