mirror of
https://github.com/zhigang1992/create-react-app.git
synced 2026-06-15 09:58:21 +08:00
Fix Code Review
This commit is contained in:
committed by
William Monk
parent
4d9c829453
commit
7014aeddda
4
.github/ISSUE_TEMPLATE.md
vendored
4
.github/ISSUE_TEMPLATE.md
vendored
@@ -83,7 +83,11 @@
|
||||
2. `node -v`:
|
||||
3. `npm -v`:
|
||||
4. `yarn --version` (if you use Yarn):
|
||||
<<<<<<< HEAD
|
||||
5. `npm ls react-scripts` (if you haven’t ejected):
|
||||
=======
|
||||
3. `npm ls react-scripts-ts` (if you haven’t ejected):
|
||||
>>>>>>> Fix Code Review
|
||||
|
||||
Then, specify:
|
||||
|
||||
|
||||
@@ -95,7 +95,17 @@ module.exports = {
|
||||
// https://github.com/facebookincubator/create-react-app/issues/290
|
||||
// `web` extension prefixes have been added for better support
|
||||
// for React Native Web.
|
||||
extensions: ['.web.ts', '.ts', '.tsx', '.web.tsx', '.web.js', '.js', '.json', '.web.jsx', '.jsx'],
|
||||
extensions: [
|
||||
'.web.ts',
|
||||
'.ts',
|
||||
'.web.tsx',
|
||||
'.tsx',
|
||||
'.web.js',
|
||||
'.js',
|
||||
'.json',
|
||||
'.web.jsx',
|
||||
'.jsx',
|
||||
],
|
||||
alias: {
|
||||
// @remove-on-eject-begin
|
||||
// Resolve Babel runtime relative to react-scripts.
|
||||
|
||||
@@ -95,7 +95,17 @@ module.exports = {
|
||||
// https://github.com/facebookincubator/create-react-app/issues/290
|
||||
// `web` extension prefixes have been added for better support
|
||||
// for React Native Web.
|
||||
extensions: ['.web.ts', '.ts', '.tsx', '.web.tsx', '.web.js', '.js', '.json', '.web.jsx', '.jsx'],
|
||||
extensions: [
|
||||
'.web.ts',
|
||||
'.ts',
|
||||
'.web.tsx',
|
||||
'.tsx',
|
||||
'.web.js',
|
||||
'.js',
|
||||
'.json',
|
||||
'.web.jsx',
|
||||
'.jsx',
|
||||
],
|
||||
alias: {
|
||||
// @remove-on-eject-begin
|
||||
// Resolve Babel runtime relative to react-scripts.
|
||||
|
||||
@@ -22,13 +22,13 @@
|
||||
"react-scripts-ts": "./bin/react-scripts-ts.js"
|
||||
},
|
||||
"dependencies": {
|
||||
"autoprefixer": "7.1.0",
|
||||
"autoprefixer": "7.1.1",
|
||||
"app-root-path": "^2.0.1",
|
||||
"case-sensitive-paths-webpack-plugin": "2.1.1",
|
||||
"chalk": "1.1.3",
|
||||
"chalk": "1.1.3",
|
||||
"cli-highlight": "1.1.4",
|
||||
"css-loader": "0.28.1",
|
||||
"css-loader": "0.28.4",
|
||||
"dotenv": "4.0.0",
|
||||
"extract-text-webpack-plugin": "2.1.2",
|
||||
"file-loader": "0.11.2",
|
||||
@@ -52,7 +52,7 @@
|
||||
"sw-precache-webpack-plugin": "0.11.3",
|
||||
"url-loader": "0.5.8",
|
||||
"webpack": "2.6.1",
|
||||
"webpack-dev-server": "2.4.5",
|
||||
"webpack-dev-server": "2.5.0",
|
||||
"webpack-manifest-plugin": "1.1.0",
|
||||
"whatwg-fetch": "2.0.3"
|
||||
},
|
||||
|
||||
@@ -27,7 +27,17 @@ module.exports = (resolve, rootDir) => {
|
||||
collectCoverageFrom: ['src/**/*.{js,jsx,ts,tsx}'],
|
||||
setupFiles: [resolve('config/polyfills.js')],
|
||||
setupTestFrameworkScriptFile: setupTestsFile,
|
||||
moduleFileExtensions: ['web.ts', 'ts', 'web.tsx', 'tsx', 'js', 'jsx', 'json'],
|
||||
moduleFileExtensions: [
|
||||
'web.ts',
|
||||
'ts',
|
||||
'web.tsx',
|
||||
'tsx',
|
||||
'web.js',
|
||||
'js',
|
||||
'web.jsx',
|
||||
'jsx',
|
||||
'json',
|
||||
],
|
||||
testMatch: [
|
||||
'<rootDir>/src/**/__tests__/**/*.ts?(x)',
|
||||
'<rootDir>/src/**/?(*.)(spec|test).ts?(x)',
|
||||
|
||||
8
packages/react-scripts/template/src/index.js
vendored
8
packages/react-scripts/template/src/index.js
vendored
@@ -1,8 +0,0 @@
|
||||
import React from 'react';
|
||||
import ReactDOM from 'react-dom';
|
||||
import './index.css';
|
||||
import App from './App';
|
||||
import registerServiceWorker from './registerServiceWorker';
|
||||
|
||||
ReactDOM.render(<App />, document.getElementById('root'));
|
||||
registerServiceWorker();
|
||||
Reference in New Issue
Block a user