parent
1a4c5f50c3
commit
349488027c
@ -0,0 +1,27 @@
|
|||||||
|
'use strict'
|
||||||
|
|
||||||
|
const { join, dirname } = require('path')
|
||||||
|
const fs = require('fs')
|
||||||
|
|
||||||
|
const cwd = process.cwd()
|
||||||
|
|
||||||
|
function replacePath (path) {
|
||||||
|
if (path.node.source && /\/lib\//.test(path.node.source.value)) {
|
||||||
|
const esModule = path.node.source.value.replace('/lib/', '/es/')
|
||||||
|
const esPath = dirname(join(cwd, `node_modules/${esModule}`))
|
||||||
|
if (fs.existsSync(esPath)) {
|
||||||
|
path.node.source.value = esModule
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
function replaceLib () {
|
||||||
|
return {
|
||||||
|
visitor: {
|
||||||
|
ImportDeclaration: replacePath,
|
||||||
|
ExportNamedDeclaration: replacePath,
|
||||||
|
},
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
module.exports = replaceLib
|
@ -1,146 +1,149 @@
|
|||||||
{
|
{
|
||||||
"name": "vue-antd3",
|
"name": "vue-antd3",
|
||||||
"version": "0.1.0",
|
"version": "0.1.0",
|
||||||
"title": "Ant Design Vue",
|
"title": "Ant Design Vue",
|
||||||
"description": "An enterprise-class UI design language and Vue-based implementation",
|
"description": "An enterprise-class UI design language and Vue-based implementation",
|
||||||
"keywords": [
|
"keywords": [
|
||||||
"ant",
|
"ant",
|
||||||
"design",
|
"design",
|
||||||
"antd",
|
"antd",
|
||||||
"vue",
|
"vue",
|
||||||
"vueComponent",
|
"vueComponent",
|
||||||
"component",
|
"component",
|
||||||
"components",
|
"components",
|
||||||
"ui",
|
"ui",
|
||||||
"framework",
|
"framework",
|
||||||
"frontend"
|
"frontend"
|
||||||
],
|
],
|
||||||
"main": "dist/antd.min.js",
|
"main": "dist/antd.min.js",
|
||||||
"files": [
|
"files": [
|
||||||
"dist",
|
"dist",
|
||||||
"components"
|
"components"
|
||||||
],
|
],
|
||||||
"scripts": {
|
"scripts": {
|
||||||
"start": "NODE_ENV=development ./node_modules/.bin/webpack-dev-server --open --hot",
|
"start": "NODE_ENV=development ./node_modules/.bin/webpack-dev-server --open --hot",
|
||||||
"test": "karma start test/karma.conf.js --single-run",
|
"test": "karma start test/karma.conf.js --single-run",
|
||||||
"build": "sh build.sh",
|
"build": "sh build.sh",
|
||||||
"dist": "node antd-tools/cli/run.js dist",
|
"compile": "node antd-tools/cli/run.js compile",
|
||||||
"lint": "eslint -c ./.eslintrc --fix --ext .jsx ./components",
|
"dist": "node antd-tools/cli/run.js dist",
|
||||||
"lint:style": "stylelint \"./examples/**/*.less\" --fix --syntax less"
|
"lint": "eslint -c ./.eslintrc --fix --ext .jsx ./components",
|
||||||
},
|
"lint:style": "stylelint \"./examples/**/*.less\" --fix --syntax less"
|
||||||
"repository": {
|
},
|
||||||
"type": "git",
|
"repository": {
|
||||||
"url": "git+https://github.com/vueComponent/ant-design.git"
|
"type": "git",
|
||||||
},
|
"url": "git+https://github.com/vueComponent/ant-design.git"
|
||||||
"license": "MIT",
|
},
|
||||||
"bugs": {
|
"license": "MIT",
|
||||||
"url": "https://github.com/vueComponent/ant-design/issues"
|
"bugs": {
|
||||||
},
|
"url": "https://github.com/vueComponent/ant-design/issues"
|
||||||
"homepage": "https://github.com/vueComponent/ant-design",
|
},
|
||||||
"pre-commit": [
|
"homepage": "https://github.com/vueComponent/ant-design",
|
||||||
"lint:style"
|
"pre-commit": [
|
||||||
],
|
"lint:style"
|
||||||
"devDependencies": {
|
],
|
||||||
"@babel/core": "^7.0.0-beta.42",
|
"devDependencies": {
|
||||||
"@babel/preset-env": "^7.0.0-beta.42",
|
"autoprefixer": "^8.1.0",
|
||||||
"autoprefixer": "^8.1.0",
|
"babel-cli": "^6.26.0",
|
||||||
"babel": "^6.23.0",
|
"babel-core": "^6.26.0",
|
||||||
"babel-cli": "^6.26.0",
|
"babel-eslint": "^8.0.1",
|
||||||
"babel-core": "^6.26.0",
|
"babel-helper-vue-jsx-merge-props": "^2.0.3",
|
||||||
"babel-eslint": "^8.0.1",
|
"babel-loader": "^7.1.2",
|
||||||
"babel-helper-vue-jsx-merge-props": "^2.0.3",
|
"babel-plugin-add-module-exports": "^0.2.1",
|
||||||
"babel-loader": "^7.1.2",
|
"babel-plugin-import": "^1.1.1",
|
||||||
"babel-plugin-add-module-exports": "^0.2.1",
|
"babel-plugin-istanbul": "^4.1.1",
|
||||||
"babel-plugin-import": "^1.6.7",
|
"babel-plugin-syntax-dynamic-import": "^6.18.0",
|
||||||
"babel-plugin-istanbul": "^4.1.1",
|
"babel-plugin-syntax-jsx": "^6.18.0",
|
||||||
"babel-plugin-syntax-dynamic-import": "^6.18.0",
|
"babel-plugin-transform-decorators": "^6.24.1",
|
||||||
"babel-plugin-syntax-jsx": "^6.18.0",
|
"babel-plugin-transform-decorators-legacy": "^1.3.4",
|
||||||
"babel-plugin-transform-decorators": "^6.24.1",
|
"babel-plugin-transform-es3-member-expression-literals": "^6.22.0",
|
||||||
"babel-plugin-transform-decorators-legacy": "^1.3.4",
|
"babel-plugin-transform-es3-property-literals": "^6.22.0",
|
||||||
"babel-plugin-transform-object-rest-spread": "^6.26.0",
|
"babel-plugin-transform-object-assign": "^6.22.0",
|
||||||
"babel-plugin-transform-vue-jsx": "^3.7.0",
|
"babel-plugin-transform-object-rest-spread": "^6.26.0",
|
||||||
"babel-polyfill": "^6.26.0",
|
"babel-plugin-transform-runtime": "~6.23.0",
|
||||||
"babel-preset-env": "^1.6.1",
|
"babel-plugin-transform-vue-jsx": "^3.7.0",
|
||||||
"case-sensitive-paths-webpack-plugin": "^2.1.2",
|
"babel-polyfill": "^6.26.0",
|
||||||
"chai": "^4.1.2",
|
"babel-preset-env": "^1.6.1",
|
||||||
"chalk": "^2.3.2",
|
"case-sensitive-paths-webpack-plugin": "^2.1.2",
|
||||||
"cheerio": "^1.0.0-rc.2",
|
"chai": "^4.1.2",
|
||||||
"colorful": "^2.1.0",
|
"chalk": "^2.3.2",
|
||||||
"commander": "^2.15.0",
|
"cheerio": "^1.0.0-rc.2",
|
||||||
"css-loader": "^0.28.7",
|
"colorful": "^2.1.0",
|
||||||
"deep-assign": "^2.0.0",
|
"commander": "^2.15.0",
|
||||||
"eslint": "^4.7.2",
|
"css-loader": "^0.28.7",
|
||||||
"eslint-plugin-html": "^3.2.2",
|
"deep-assign": "^2.0.0",
|
||||||
"eslint-plugin-vue-libs": "^1.2.1",
|
"eslint": "^4.7.2",
|
||||||
"extract-text-webpack-plugin": "^3.0.2",
|
"eslint-plugin-html": "^3.2.2",
|
||||||
"fetch-jsonp": "^1.1.3",
|
"eslint-plugin-vue-libs": "^1.2.1",
|
||||||
"gulp": "^3.9.1",
|
"extract-text-webpack-plugin": "^3.0.2",
|
||||||
"gulp-babel": "^8.0.0-beta.2",
|
"fetch-jsonp": "^1.1.3",
|
||||||
"highlight.js": "^9.12.0",
|
"gulp": "^3.9.1",
|
||||||
"html-webpack-plugin": "^2.30.1",
|
"gulp-babel": "^7.0.0",
|
||||||
"istanbul-instrumenter-loader": "^3.0.0",
|
"gulp-strip-code": "^0.1.4",
|
||||||
"jsonp": "^0.2.1",
|
"highlight.js": "^9.12.0",
|
||||||
"karma": "^1.4.1",
|
"html-webpack-plugin": "^2.30.1",
|
||||||
"karma-coverage": "^1.1.1",
|
"istanbul-instrumenter-loader": "^3.0.0",
|
||||||
"karma-coverage-istanbul-reporter": "^1.3.0",
|
"jsonp": "^0.2.1",
|
||||||
"karma-mocha": "^1.3.0",
|
"karma": "^1.4.1",
|
||||||
"karma-phantomjs-launcher": "^1.0.2",
|
"karma-coverage": "^1.1.1",
|
||||||
"karma-phantomjs-shim": "^1.4.0",
|
"karma-coverage-istanbul-reporter": "^1.3.0",
|
||||||
"karma-sinon-chai": "^1.3.1",
|
"karma-mocha": "^1.3.0",
|
||||||
"karma-sourcemap-loader": "^0.3.7",
|
"karma-phantomjs-launcher": "^1.0.2",
|
||||||
"karma-spec-reporter": "0.0.31",
|
"karma-phantomjs-shim": "^1.4.0",
|
||||||
"karma-webpack": "^2.0.2",
|
"karma-sinon-chai": "^1.3.1",
|
||||||
"less": "^2.7.2",
|
"karma-sourcemap-loader": "^0.3.7",
|
||||||
"less-loader": "^4.0.5",
|
"karma-spec-reporter": "0.0.31",
|
||||||
"less-plugin-npm-import": "^2.1.0",
|
"karma-webpack": "^2.0.2",
|
||||||
"markdown-it": "^8.4.0",
|
"less": "^2.7.2",
|
||||||
"marked": "^0.3.7",
|
"less-loader": "^4.0.5",
|
||||||
"merge2": "^1.2.1",
|
"less-plugin-npm-import": "^2.1.0",
|
||||||
"mocha": "^3.2.0",
|
"markdown-it": "^8.4.0",
|
||||||
"postcss": "^6.0.20",
|
"marked": "^0.3.7",
|
||||||
"postcss-loader": "^2.1.2",
|
"merge2": "^1.2.1",
|
||||||
"pre-commit": "^1.2.2",
|
"mocha": "^3.2.0",
|
||||||
"querystring": "^0.2.0",
|
"postcss": "^6.0.20",
|
||||||
"rimraf": "^2.6.2",
|
"postcss-loader": "^2.1.2",
|
||||||
"rucksack-css": "^1.0.2",
|
"pre-commit": "^1.2.2",
|
||||||
"selenium-server": "^3.0.1",
|
"querystring": "^0.2.0",
|
||||||
"semver": "^5.3.0",
|
"rimraf": "^2.6.2",
|
||||||
"sinon": "^4.0.2",
|
"rucksack-css": "^1.0.2",
|
||||||
"sinon-chai": "^2.8.0",
|
"selenium-server": "^3.0.1",
|
||||||
"style-loader": "^0.18.2",
|
"semver": "^5.3.0",
|
||||||
"stylelint": "^8.1.1",
|
"sinon": "^4.0.2",
|
||||||
"stylelint-config-standard": "^17.0.0",
|
"sinon-chai": "^2.8.0",
|
||||||
"through2": "^2.0.3",
|
"style-loader": "^0.18.2",
|
||||||
"vue-antd-md-loader": "^1.0.2",
|
"stylelint": "^8.1.1",
|
||||||
"vue-loader": "^13.0.5",
|
"stylelint-config-standard": "^17.0.0",
|
||||||
"vue-router": "^3.0.1",
|
"through2": "^2.0.3",
|
||||||
"vue-template-compiler": "^2.5.15",
|
"vue-antd-md-loader": "^1.0.2",
|
||||||
"webpack": "^3.6.0",
|
"vue-loader": "^13.0.5",
|
||||||
"webpack-chunk-hash": "^0.5.0",
|
"vue-router": "^3.0.1",
|
||||||
"webpack-dev-server": "^2.8.2",
|
"vue-template-compiler": "^2.5.15",
|
||||||
"webpack-merge": "^4.1.1"
|
"webpack": "^3.6.0",
|
||||||
},
|
"webpack-chunk-hash": "^0.5.0",
|
||||||
"dependencies": {
|
"webpack-dev-server": "^2.8.2",
|
||||||
"add-dom-event-listener": "^1.0.2",
|
"webpack-merge": "^4.1.1"
|
||||||
"array-tree-filter": "^2.1.0",
|
},
|
||||||
"classnames": "^2.2.5",
|
"dependencies": {
|
||||||
"component-classes": "^1.2.6",
|
"add-dom-event-listener": "^1.0.2",
|
||||||
"css-animation": "^1.4.1",
|
"array-tree-filter": "^2.1.0",
|
||||||
"dom-align": "^1.6.7",
|
"classnames": "^2.2.5",
|
||||||
"dom-scroll-into-view": "^1.2.1",
|
"component-classes": "^1.2.6",
|
||||||
"enquire.js": "^2.1.6",
|
"css-animation": "^1.4.1",
|
||||||
"eslint-plugin-vue": "^3.13.0",
|
"dom-align": "^1.6.7",
|
||||||
"lodash.clonedeep": "^4.5.0",
|
"dom-scroll-into-view": "^1.2.1",
|
||||||
"lodash.debounce": "^4.0.8",
|
"enquire.js": "^2.1.6",
|
||||||
"lodash.isequal": "^4.5.0",
|
"eslint-plugin-vue": "^3.13.0",
|
||||||
"lodash.isplainobject": "^4.0.6",
|
"lodash.clonedeep": "^4.5.0",
|
||||||
"moment": "^2.21.0",
|
"lodash.debounce": "^4.0.8",
|
||||||
"omit.js": "^1.0.0",
|
"lodash.isequal": "^4.5.0",
|
||||||
"shallow-equal": "^1.0.0",
|
"lodash.isplainobject": "^4.0.6",
|
||||||
"shallowequal": "^1.0.2",
|
"moment": "^2.21.0",
|
||||||
"vue": "^2.5.15",
|
"omit.js": "^1.0.0",
|
||||||
"vue-clipboard2": "0.0.8",
|
"shallow-equal": "^1.0.0",
|
||||||
"vue-types": "^1.0.2",
|
"shallowequal": "^1.0.2",
|
||||||
"warning": "^3.0.0"
|
"vue": "^2.5.15",
|
||||||
}
|
"vue-clipboard2": "0.0.8",
|
||||||
|
"vue-types": "^1.0.2",
|
||||||
|
"warning": "^3.0.0"
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in new issue