use rollup script for publish prepare script

rm rollup script update ref to build script
This commit is contained in:
Brian Ignacio 2023-01-17 10:36:34 +08:00
parent 4bac4457db
commit 541c71ef93
3 changed files with 5 additions and 6 deletions

View File

@ -33,7 +33,7 @@ jobs:
- name: Install Node modules
run: |
npm install
npm run rollup
npm run build
- name: Setup Pages
uses: actions/configure-pages@v2
- name: Upload artifact

View File

@ -12,11 +12,11 @@ Visit https://espressif.github.io/esptool-js/ to see this tool in action.
```
npm install
npm run rollup
npm run build
python3 -m http.server 8008
```
Then open http://localhost:8008 in Chrome or Edge. The `npm run rollup` step builds the `bundle.js` used in the example `index.html`.
Then open http://localhost:8008 in Chrome or Edge. The `npm run build` step builds the `bundle.js` used in the example `index.html`.
## License

View File

@ -9,15 +9,14 @@
"bundle.js"
],
"scripts": {
"build": "npm run clean && tsc",
"build": "npm run clean && tsc && rollup --config",
"clean": "rimraf lib bundle.js",
"format": "prettier --write \"src/**/*.ts\"",
"lint": "eslint . --ext .ts",
"lintAndFix": "eslint . --ext .ts --fix",
"prepare": "npm run build",
"test": "echo \"Error: no test specified\"",
"prepublishOnly": "npm run test && npm run lint",
"rollup": "npm run build && rollup --config"
"prepublishOnly": "npm run test && npm run lint"
},
"repository": {
"type": "git",