尝试修复 amis-formula 没有类型文件的问题

This commit is contained in:
2betop 2022-06-07 17:33:25 +08:00
parent 9e4feeca12
commit 1406892cb1
3 changed files with 40 additions and 2 deletions

View File

@ -62,6 +62,7 @@ import FormItem, {
FormBaseControl,
FormControlProps,
FormItemWrap,
FormItemProps,
registerFormItem
} from './renderers/Item';
import {
@ -101,6 +102,7 @@ export {
RegisterStore,
FormItem,
FormItemWrap,
FormItemProps,
OptionsControl,
FormRenderer,
FormHorizontal,

View File

@ -4,10 +4,10 @@
"description": "负责 amis 里面的表达式实现,内置公式,编辑器等",
"main": "lib/index.js",
"scripts": {
"build": "npm run clean-dist && NODE_ENV=production rollup -c && npm run declaration && npm run genDoc",
"build": "npm run clean-dist && NODE_ENV=production rollup -c && npm run genDoc && npm run declaration ",
"lib": "npm run clean-dist && NODE_ENV=lib rollup -c",
"clean-dist": "rimraf lib/*",
"declaration": "tsc --allowJs --declaration --emitDeclarationOnly --declarationDir ./lib --rootDir ./src",
"declaration": "tsc --project tsconfig-for-declaration.json --allowJs --declaration --emitDeclarationOnly --declarationDir ./lib --rootDir ./src",
"test": "jest",
"coverage": "jest --coverage",
"genDoc": "ts-node ./scripts/genDoc.ts"

View File

@ -0,0 +1,36 @@
{
"compilerOptions": {
"outDir": "lib/",
"module": "commonjs",
"target": "es5",
"lib": ["es6", "dom", "ES2015"],
"sourceMap": true,
"jsx": "react",
"moduleResolution": "node",
"rootDir": "",
"importHelpers": true,
"esModuleInterop": true,
"allowSyntheticDefaultImports": true,
"sourceRoot": "src",
"noImplicitReturns": true,
"noImplicitThis": true,
"noImplicitAny": true,
"strictNullChecks": true,
"experimentalDecorators": true,
"emitDecoratorMetadata": true,
"skipLibCheck": true,
"skipDefaultLibCheck": true,
"allowJs": true
},
"include": ["src/**/*"],
"exclude": [
"node_modules",
"build",
"scripts",
"acceptance-tests",
"webpack",
"jest",
"src/setupTests.ts"
],
"types": ["typePatches"]
}