a00cc184 by McLemore

build: resolve ts file

1 parent ddfa7479
### 组件简介
### 使用方法
### 开始开发
1. 本地执行`npm run dev`
......
......@@ -2,6 +2,25 @@
"parser": "@typescript-eslint/parser",
"plugins": ["@typescript-eslint"],
"extends": ["airbnb-base", "plugin:@typescript-eslint/recommended"],
"rules": {
"no-restricted-globals": "off",
"no-restricted-properties": "off",
"import/extensions": [
"error",
"ignorePackages",
{
"js": "never",
"ts": "never"
}
]
},
"settings": {
"import/resolver": {
"node": {
"extensions": [".js", ".ts"]
}
}
},
"globals": {
"window": true,
"document": true,
......
......@@ -6,7 +6,7 @@ const ts = require('gulp-typescript')
const dist = 'miniprogram_dist'
const demoDir = 'demo'
const lessFiles = ['./src/index.less']
const tsFiles = ['./src/index.ts']
const tsFiles = ['./src/*.ts']
const tsProject = ts.createProject('tsconfig.json')
......
......@@ -4,6 +4,7 @@
"./node_modules/miniprogram-api-typings"
],
"lib": ["ES6", "ES7"],
"target": "es2017"
"target": "es2017",
"module": "CommonJS"
}
}
\ No newline at end of file
......