Skip to content

Commit

Permalink
flatten the published directory (#6)
Browse files Browse the repository at this point in the history
  • Loading branch information
nicnocquee authored Dec 27, 2019
1 parent 32c20e6 commit a3b9049
Show file tree
Hide file tree
Showing 4 changed files with 25 additions and 12 deletions.
3 changes: 2 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@ examples/RNUpdateCheckerExample/ios/Pods/

# production
/build
/dist

# misc
/.DS_Store
Expand All @@ -22,4 +23,4 @@ examples/RNUpdateCheckerExample/ios/Pods/

npm-debug.log*
yarn-debug.log*
yarn-error.log*
yarn-error.log*
3 changes: 2 additions & 1 deletion .npmignore
Original file line number Diff line number Diff line change
@@ -1 +1,2 @@
/examples
/examples
src/**/*.test.js
10 changes: 9 additions & 1 deletion babel.config.js
Original file line number Diff line number Diff line change
@@ -1,3 +1,11 @@
module.exports = {
presets: ["module:metro-react-native-babel-preset"]
presets: ["module:metro-react-native-babel-preset"],
env: {
production: {
ignore: [
"**/*.test.js"
],
sourceMaps: true
}
}
};
21 changes: 12 additions & 9 deletions package.json
Original file line number Diff line number Diff line change
@@ -1,15 +1,13 @@
{
"name": "@hyperjumptech/universal-update-checker",
"version": "0.0.2",
"version": "0.0.3",
"description": "React component to check if there is a new version of the app",
"main": "src/index.js",
"files": [
"src"
],
"main": "build/index.js",
"files": ["build"],
"scripts": {
"build": "rm -rf build && publish-flat -f src -o build && cd build && npm pack",
"test": "jest src",
"develop": "cd src && sync-glob --watch . ../examples/RNUpdateCheckerExample/node_modules/universal-update-checker"
"build-module": "rm -rf build && rm -rf dist && NODE_ENV=production babel src --out-dir build && publish-flat -f build -o dist",
"publish-module": "npm run build-module && cd dist && npm publish",
"test": "jest src"
},
"repository": {
"type": "git",
Expand All @@ -30,7 +28,12 @@
},
"jest": {
"preset": "react-native",
"testEnvironment": "jsdom"
"testEnvironment": "jsdom",
"testPathIgnorePatterns": [
"<rootDir>/build/",
"<rootDir>/dist/",
"<rootDir>/node_modules/"
]
},
"devDependencies": {
"@babel/cli": "^7.5.5",
Expand Down

0 comments on commit a3b9049

Please sign in to comment.