提交 6e9dc0f9340eed7cbe74cae5f74e2a8b09b2242b

作者 sorrycc
1 个父辈 b30f6746

scripts -> _scripts, ...

@@ -20,12 +20,12 @@ module.exports = { @@ -20,12 +20,12 @@ module.exports = {
20 'react/prop-types': 0, 20 'react/prop-types': 0,
21 'react/forbid-prop-types': 0, 21 'react/forbid-prop-types': 0,
22 'react/jsx-one-expression-per-line': 0, 22 'react/jsx-one-expression-per-line': 0,
23 - 'import/no-unresolved': [2, { ignore: ['^@/', '^umi/'] }], 23 + 'import/no-unresolved': 0,
24 'import/no-extraneous-dependencies': [ 24 'import/no-extraneous-dependencies': [
25 2, 25 2,
26 { 26 {
27 optionalDependencies: true, 27 optionalDependencies: true,
28 - devDependencies: ['**/tests/**.js', '/mock/**.js', '**/**.test.js'], 28 + devDependencies: ['**/tests/**.js', '/mock/**.js', '**/**.test.js', '**/_scripts/*.js'],
29 }, 29 },
30 ], 30 ],
31 'jsx-a11y/no-noninteractive-element-interactions': 0, 31 'jsx-a11y/no-noninteractive-element-interactions': 0,
@@ -6,9 +6,9 @@ @@ -6,9 +6,9 @@
6 *----------*****-------------- 6 *----------*****--------------
7 */ 7 */
8 8
9 -const glob = require('glob');  
10 const prettier = require('prettier'); 9 const prettier = require('prettier');
11 const fs = require('fs'); 10 const fs = require('fs');
  11 +
12 const prettierConfigPath = require.resolve('../.prettierrc'); 12 const prettierConfigPath = require.resolve('../.prettierrc');
13 13
14 const files = process.argv.slice(2); 14 const files = process.argv.slice(2);
@@ -9,6 +9,7 @@ @@ -9,6 +9,7 @@
9 const glob = require('glob'); 9 const glob = require('glob');
10 const prettier = require('prettier'); 10 const prettier = require('prettier');
11 const fs = require('fs'); 11 const fs = require('fs');
  12 +
12 const prettierConfigPath = require.resolve('../.prettierrc'); 13 const prettierConfigPath = require.resolve('../.prettierrc');
13 14
14 let didError = false; 15 let didError = false;
1 -  
2 import request from 'umi-request'; 1 import request from 'umi-request';
3 2
4 export async function queryFakeList(params) { 3 export async function queryFakeList(params) {
@@ -32,7 +32,7 @@ export default class StepForm extends PureComponent { @@ -32,7 +32,7 @@ export default class StepForm extends PureComponent {
32 if (/confirm\/?$/.test(pathname)) { 32 if (/confirm\/?$/.test(pathname)) {
33 currentStep = <Step2 />; 33 currentStep = <Step2 />;
34 } else if (/result\/?$/.test(pathname)) { 34 } else if (/result\/?$/.test(pathname)) {
35 - currentStep = <Step3 />; 35 + currentStep = <Step3 />;
36 } else { 36 } else {
37 currentStep = <Step1 />; 37 currentStep = <Step1 />;
38 } 38 }
1 -  
2 import nzh from 'nzh/cn'; 1 import nzh from 'nzh/cn';
3 2
4 export function digitUppercase(n) { 3 export function digitUppercase(n) {
1 { 1 {
2 - "name": "ant-design-pro",  
3 - "version": "2.1.1",  
4 - "description": "An out-of-box UI solution for enterprise applications",  
5 "private": true, 2 "private": true,
6 "scripts": { 3 "scripts": {
7 "lint:style": "stylelint \"src/**/*.less\" --syntax less", 4 "lint:style": "stylelint \"src/**/*.less\" --syntax less",
@@ -9,23 +6,10 @@ @@ -9,23 +6,10 @@
9 "lint:fix": "eslint --fix --ext .js src mock tests && npm run lint:style", 6 "lint:fix": "eslint --fix --ext .js src mock tests && npm run lint:style",
10 "lint-staged": "lint-staged", 7 "lint-staged": "lint-staged",
11 "lint-staged:js": "eslint --ext .js", 8 "lint-staged:js": "eslint --ext .js",
12 - "tslint": "npm run tslint:fix",  
13 - "tslint:fix": "tslint --fix 'src/**/*.ts*'",  
14 - "test": "umi test",  
15 - "test:component": "umi test ./src/components",  
16 - "test:all": "node ./tests/run-tests.js",  
17 - "prettier": "node ./scripts/prettier.js"  
18 - },  
19 - "dependencies": {  
20 - 9 + "prettier": "node ./_scripts/prettier.js"
21 }, 10 },
22 "devDependencies": { 11 "devDependencies": {
23 - "@types/react": "^16.7.7",  
24 - "@types/react-dom": "^16.0.10",  
25 "babel-eslint": "^10.0.1", 12 "babel-eslint": "^10.0.1",
26 - "cross-env": "^5.1.1",  
27 - "cross-port-killer": "^1.0.1",  
28 - "enzyme": "^3.7.0",  
29 "eslint": "^5.4.0", 13 "eslint": "^5.4.0",
30 "eslint-config-airbnb": "^17.0.0", 14 "eslint-config-airbnb": "^17.0.0",
31 "eslint-config-prettier": "^3.0.1", 15 "eslint-config-prettier": "^3.0.1",
@@ -35,40 +19,22 @@ @@ -35,40 +19,22 @@
35 "eslint-plugin-jsx-a11y": "^6.1.2", 19 "eslint-plugin-jsx-a11y": "^6.1.2",
36 "eslint-plugin-markdown": "^1.0.0-beta.6", 20 "eslint-plugin-markdown": "^1.0.0-beta.6",
37 "eslint-plugin-react": "^7.11.1", 21 "eslint-plugin-react": "^7.11.1",
38 - "gh-pages": "^2.0.1", 22 + "glob": "^7.1.3",
39 "husky": "^1.2.0", 23 "husky": "^1.2.0",
40 - "jest-puppeteer": "^3.5.1",  
41 "lint-staged": "^8.1.0", 24 "lint-staged": "^8.1.0",
42 - "merge-umi-mock-data": "^0.0.3",  
43 - "mockjs": "^1.0.1-beta3",  
44 "prettier": "1.15.2", 25 "prettier": "1.15.2",
45 - "pro-download": "^1.0.1",  
46 "stylelint": "^9.8.0", 26 "stylelint": "^9.8.0",
47 "stylelint-config-prettier": "^4.0.0", 27 "stylelint-config-prettier": "^4.0.0",
48 - "stylelint-config-standard": "^18.0.0",  
49 - "tslint": "^5.10.0",  
50 - "tslint-config-prettier": "^1.10.0",  
51 - "tslint-react": "^3.6.0"  
52 - },  
53 - "optionalDependencies": {  
54 - "puppeteer": "^1.10.0" 28 + "stylelint-config-standard": "^18.0.0"
55 }, 29 },
56 "lint-staged": { 30 "lint-staged": {
57 - "**/*.{js,ts,tsx,json,jsx,less}": [  
58 - "node ./scripts/lint-prettier.js", 31 + "x/**/*.{js,ts,tsx,json,jsx,less}": [
  32 + "node ./_scripts/lint-prettier.js",
59 "git add" 33 "git add"
60 ], 34 ],
61 "**/*.{js,jsx}": "npm run lint-staged:js", 35 "**/*.{js,jsx}": "npm run lint-staged:js",
62 "**/*.less": "stylelint --syntax less" 36 "**/*.less": "stylelint --syntax less"
63 }, 37 },
64 - "engines": {  
65 - "node": ">=8.0.0"  
66 - },  
67 - "browserslist": [  
68 - "> 1%",  
69 - "last 2 versions",  
70 - "not ie <= 10"  
71 - ],  
72 "husky": { 38 "husky": {
73 "hooks": { 39 "hooks": {
74 "pre-commit": "npm run lint-staged" 40 "pre-commit": "npm run lint-staged"
注册登录 后发表评论