Skip to content

Commit

Permalink
chore: add script to build API docs [skip ci] (#561)
Browse files Browse the repository at this point in the history
  • Loading branch information
web-padawan authored Dec 7, 2020
1 parent 590025d commit 5b616b9
Show file tree
Hide file tree
Showing 3 changed files with 22 additions and 1 deletion.
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -3,4 +3,5 @@ node_modules
package-lock.json
yarn.lock
coverage
dist
analysis.json
10 changes: 9 additions & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -25,15 +25,18 @@
"theme"
],
"scripts": {
"analyze": "polymer analyze vaadin-* > analysis.json",
"debug": "web-test-runner test/*.test.js --watch",
"dist": "rimraf dist && npm run analyze && rollup -c rollup.config.js && cp analysis.json dist",
"check-version": "magi check-version",
"lint": "npm run lint:js && npm run lint:css && npm run lint:types",
"lint:css": "stylelint src/*.js theme/**/*-styles.js",
"lint:js": "eslint src theme test",
"lint:types": "tsc",
"prestart": "polymer analyze vaadin-* > analysis.json",
"prestart": "npm run analyze",
"preversion": "magi update-version",
"screenshots": "hermione test/visual/test.js --update-refs",
"serve:dist": "web-dev-server --app-index dist/index.html --open",
"start": "web-dev-server --node-resolve --open",
"test": "web-test-runner test/*.test.js --coverage",
"test:sauce": "TEST_ENV=sauce npm test",
Expand All @@ -60,9 +63,11 @@
},
"devDependencies": {
"@esm-bundle/chai": "^4.1.5",
"@open-wc/rollup-plugin-html": "^1.2.5",
"@open-wc/testing-helpers": "^1.8.12",
"@polymer/iron-component-page": "^4.0.0",
"@polymer/iron-test-helpers": "^3.0.0",
"@rollup/plugin-node-resolve": "^11.0.0",
"@web/dev-server": "0.0.24",
"@web/test-runner": "^0.9.13",
"@web/test-runner-saucelabs": "^0.1.3",
Expand All @@ -76,6 +81,9 @@
"lint-staged": "^10.5.1",
"magi-cli": "^0.28.0",
"prettier": "^2.2.0",
"rimraf": "^3.0.2",
"rollup": "^2.34.1",
"rollup-plugin-terser": "^7.0.2",
"sinon": "^9.2.1",
"stylelint": "^13.8.0",
"stylelint-config-prettier": "^8.0.2",
Expand Down
12 changes: 12 additions & 0 deletions rollup.config.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
/* eslint-env node */
const { nodeResolve } = require('@rollup/plugin-node-resolve');
const { terser } = require('rollup-plugin-terser');
const html = require('@open-wc/rollup-plugin-html');

module.exports = {
input: './index.html',
output: {
dir: './dist'
},
plugins: [html(), nodeResolve(), terser()]
};

0 comments on commit 5b616b9

Please sign in to comment.