Skip to content

Commit 7a4627c

Browse files
authored
Fix generated JS files to include propTypes (#995)
1 parent 167f8a7 commit 7a4627c

File tree

3 files changed

+6
-4
lines changed

3 files changed

+6
-4
lines changed

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@
2828
"build:dev": "tsc --p tsconfig.dev.json",
2929
"build:exports": "./node_modules/.bin/babel src --out-dir src --config-file ./src/.babelrc.json --extensions '.ts,.tsx' --ignore 'src/index.ts'",
3030
"build:packages": "node scripts/buildPackages.js",
31-
"build": "tsc --p tsconfig.build.json && npm run build:packages",
31+
"build": "tsc --p tsconfig.build.json && npm run build:exports && npm run build:packages",
3232
"log": "react-native log-ios | grep 'ethan -'",
3333
"docs:install": "(cd ./uilib-docs && rm -rf node_modules && rm -rf package-lock.json && npm install)",
3434
"docs:deploy": "(cd ./uilib-docs && gatsby build --prefix-paths && gh-pages -d public --branch gh-pages)",

src/.babelrc.json

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,6 @@
11
{
2-
"presets": ["@babel/preset-typescript", "@babel/preset-react"],
3-
"plugins": ["babel-plugin-typescript-to-proptypes"]
2+
"presets": ["@babel/preset-typescript" /* , "@babel/preset-react" */],
3+
"plugins": ["babel-plugin-typescript-to-proptypes"],
4+
"compact": false,
5+
"minified": false
46
}

tsconfig.build.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
{
22
"extends": "./tsconfig",
33
"compilerOptions": {
4-
"emitDeclarationOnly": false
4+
"emitDeclarationOnly": true
55
},
66
"include": ["src/**/*", "typings/**/*"],
77
"exclude": [ "node_modules", "src/index.ts"]

0 commit comments

Comments
 (0)