Skip to content

Commit

Permalink
chore: make taro-ui can build
Browse files Browse the repository at this point in the history
  • Loading branch information
Garfield550 committed Apr 5, 2020
1 parent f30a432 commit 3b4fa76
Show file tree
Hide file tree
Showing 12 changed files with 57 additions and 294 deletions.
23 changes: 0 additions & 23 deletions packages/taro-ui/config/dev.js

This file was deleted.

103 changes: 0 additions & 103 deletions packages/taro-ui/config/index.js

This file was deleted.

19 changes: 0 additions & 19 deletions packages/taro-ui/config/prod.js

This file was deleted.

2 changes: 1 addition & 1 deletion packages/taro-ui/config/rollup.config.js
Expand Up @@ -54,7 +54,7 @@ export default {
}),
RollupJson(),
RollupTypescript({
tsconfig: NodePath.resolve(__dirname, 'tsconfig.rollup.json')
tsconfig: resolveFile('tsconfig.rollup.json')
}),
RollupCopy({
targets: [
Expand Down
18 changes: 0 additions & 18 deletions packages/taro-ui/config/tsconfig.build.json

This file was deleted.

19 changes: 0 additions & 19 deletions packages/taro-ui/config/tsconfig.rollup.json

This file was deleted.

115 changes: 5 additions & 110 deletions packages/taro-ui/package.json
Expand Up @@ -29,23 +29,13 @@
},
"license": "MIT",
"scripts": {
"dev:weapp": "yarn run build:weapp -- --watch",
"dev:qq": "yarn run build:qq -- --watch",
"dev:h5": "yarn run build:h5 -- --watch",
"dev:swan": "yarn run build:swan -- --watch",
"dev:alipay": "yarn run build:alipay -- --watch",
"dev:doc": "yarn run build:h5-static && node ./build/dev-server",
"build:weapp": "taro build --type weapp",
"build:qq": "taro build --type qq",
"build:h5": "taro build --type h5",
"build:swan": "taro build --type swan",
"build:alipay": "taro build --type alipay",
"build:lib": "tsc --project ./config/tsconfig.build.json",
"build": "yarn run build:rollup && yarn run build:lib",
"build:lib": "tsc --project ./tsconfig.build.json",
"build:rollup": "rollup --config ./config/rollup.config.js",
"build:component": "yarn run build:rollup && yarn run build:lib",
"build:h5-static": "yarn run build:h5 && node ./build/build-static",
"build:doc": "yarn run build:h5-static && node ./build/build-docs",
"prepublishOnly": "yarn run clean && yarn run build:component",
"prepublishOnly": "yarn run clean && yarn run build",
"lint": "eslint ./src --fix",
"lint:style": "stylelint \"src/**/*.scss\" --syntax scss",
"lint:style-fix": "stylelint \"src/**/*.scss\" --syntax scss --fix",
Expand All @@ -62,118 +52,23 @@
"prop-types": "^15.7.2"
},
"devDependencies": {
"@babel/core": "^7.0.0",
"@babel/plugin-proposal-class-properties": "^7.0.0",
"@babel/plugin-proposal-decorators": "^7.8.3",
"@babel/plugin-proposal-object-rest-spread": "^7.0.0",
"@babel/plugin-transform-react-jsx": "^7.0.0",
"@babel/preset-env": "^7.0.0",
"@babel/preset-typescript": "^7.9.0",
"@commitlint/cli": "^8.2.0",
"@commitlint/config-conventional": "^8.2.0",
"@mapbox/jsxtreme-markdown-loader": "^0.8.3",
"@rollup/plugin-commonjs": "^11.0.2",
"@rollup/plugin-json": "^4.0.2",
"@rollup/plugin-node-resolve": "^7.1.1",
"@tarojs/cli": "^3.0.0-beta.2",
"@tarojs/components": "^3.0.0-beta.2",
"@tarojs/mini-runner": "^3.0.0-beta.2",
"@tarojs/plugin-babel": "^2.0.3",
"@tarojs/plugin-csso": "^2.0.3",
"@tarojs/plugin-sass": "^2.0.3",
"@tarojs/plugin-uglifyjs": "^2.0.3",
"@tarojs/react": "^3.0.0-beta.2",
"@tarojs/router": "^2.0.3",
"@tarojs/taro": "^3.0.0-beta.2",
"@tarojs/taro-h5": "^2.0.3",
"@tarojs/webpack-runner": "^2.0.3",
"@types/classnames": "^2.2.9",
"@types/node": "^13.11.0",
"@types/react": "^16.9.23",
"@types/react-dom": "^16.9.5",
"@types/webpack-env": "^1.13.6",
"@typescript-eslint/eslint-plugin": "^2.10.0",
"@typescript-eslint/parser": "^2.10.0",
"at-ui-style": "^1.5.1",
"autoprefixer": "^9.0.2",
"babel-core": "^7.0.0-0",
"babel-eslint": "^10.0.3",
"babel-jest": "23.6.0",
"babel-loader": "^8.0.0",
"babel-plugin-syntax-dynamic-import": "^6.18.0",
"babel-plugin-transform-class-properties": "^6.24.1",
"babel-plugin-transform-decorators-legacy": "^1.3.4",
"babel-plugin-transform-object-rest-spread": "^6.26.0",
"babel-preset-env": "^1.6.1",
"chalk": "^3.0.0",
"classnames": "^2.2.6",
"clean-webpack-plugin": "^3.0.0",
"commitlint": "^8.2.0",
"conventional-changelog-cli": "^2.0.11",
"copy-to-clipboard": "^3.0.8",
"copy-webpack-plugin": "^5.0.5",
"cross-env": "^7.0.0",
"css-loader": "^3.2.1",
"eslint": "^6.7.2",
"eslint-config-o2team": "^0.1.6",
"eslint-config-prettier": "^6.10.0",
"eslint-config-taro": "^2.0.3",
"eslint-plugin-import": "^2.12.0",
"eslint-plugin-jest": "^23.1.1",
"eslint-plugin-prettier": "^3.1.2",
"eslint-plugin-react": "^7.8.2",
"eslint-plugin-react-hooks": "^2.1.1",
"favicons-webpack-plugin": "2.1.0",
"file-loader": "^5.0.2",
"front-matter": "^3.0.2",
"fs-extra": "^8.1.0",
"glob": "^7.1.2",
"highlight.js": "^9.12.0",
"html-webpack-plugin": "^3.2.0",
"html-withimg-loader": "^0.1.16",
"husky": "^4.0.3",
"jest": "23.6.0",
"json-loader": "^0.5.7",
"lint-staged": "^9.5.0",
"loader-utils": "^1.1.0",
"markdown-it": "^10.0.0",
"markdown-it-container": "^2.0.0",
"markdown-it-react-loader": "1.0.0",
"mini-css-extract-plugin": "^0.9.0",
"nerv-server": "^1.5.1",
"nerv-test-utils": "^1.5.1",
"nervjs": "^1.5.6",
"ora": "^4.0.3",
"postcss": "^7.0.2",
"postcss-loader": "^3.0.0",
"prettier": "^1.19.1",
"qrcode.react": "^1.0.0",
"react": "^16.13.0",
"react-dom": "^16.13.0",
"react-markdown-loader": "^1.1.14",
"react-router-dom": "^5.1.2",
"regenerator-runtime": "^0.13.3",
"rimraf": "^3.0.2",
"rollup": "^2.3.1",
"rollup-plugin-copy": "^3.3.0",
"rollup-plugin-typescript2": "^0.27.0",
"rollup-plugin-visualizer": "^4.0.2",
"sass-loader": "^8.0.0",
"simulant": "^0.2.2",
"source-map-loader": "^0.2.4",
"stylelint": "^13.0.0",
"stylelint-config-standard": "^20.0.0",
"stylelint-scss": "^3.2.0",
"terser": "^4.4.2",
"ts-loader": "^6.2.2",
"typescript": "^3.8.3",
"url-loader": "^3.0.0",
"vue": "^2.6.11",
"webpack": "^4.42.1",
"webpack-bundle-analyzer": "^3.6.1",
"webpack-cli": "^3.3.11",
"webpack-dev-server": "^3.1.5",
"webpack-merge": "^4.1.3",
"yaml-loader": "^0.5.0"
"typescript": "^3.8.3"
},
"peerDependencies": {
"@tarojs/components": ">=3.0.0-beta.2",
Expand Down
11 changes: 11 additions & 0 deletions packages/taro-ui/tsconfig.build.json
@@ -0,0 +1,11 @@
{
"extends": "../../tsconfig.build",
"compilerOptions": {
"target": "es2017",
"module": "es6",
"outDir": "./lib"
},
"include": [
"src/**/*"
]
}
12 changes: 12 additions & 0 deletions packages/taro-ui/tsconfig.json
@@ -0,0 +1,12 @@
{
"extends": "../../tsconfig",
"compilerOptions": {
"target": "es2017",
"module": "commonjs",
"baseUrl": "./",
"typeRoots": [
"node_modules/@types",
"types"
]
}
}
13 changes: 13 additions & 0 deletions packages/taro-ui/tsconfig.rollup.json
@@ -0,0 +1,13 @@
{
"extends": "../../tsconfig.build",
"compilerOptions": {
"target": "es5",
"module": "es6",
"downlevelIteration": true,
"baseUrl": ".",
"types": ["node"]
},
"include": [
"src/**/*"
]
}
Expand Up @@ -9,9 +9,14 @@
"noUnusedLocals": true,
"noUnusedParameters": true,
"preserveConstEnums": true,
"skipLibCheck": true,
"sourceMap": true,
"strictNullChecks": true,
"resolveJsonModule": true
},
"compileOnSave": false
"compileOnSave": false,
"exclude": [
"node_modules/*",
"packages/dist/*"
]
}

0 comments on commit 3b4fa76

Please sign in to comment.