* chore(deps): upgrade prettier to v1.8.2 * chore: setup lint-docs script * docs: add `<!-- prettier-ignore -->`s * docs: format docs * Revert "docs: format docs" This reverts commit 6dba903987dddc498cb589ca311905f25b6aee53. * chore(prettierrc): set `--no-prose-wrap` * docs: format docs * Revert "docs: format docs" This reverts commit 139bd744b6921916be8fac4fa3bab83bae5d12df. * docs: tweak * docs: format docs * chore: rename .prettierrc * chore: rename back to .prettierrc * chore: split out third-party * refactor: fix linting * chore: do not split out third-party on website
31 lines
754 B
JavaScript
31 lines
754 B
JavaScript
import baseConfig from "./rollup.base.config.js";
|
|
import resolve from "rollup-plugin-node-resolve";
|
|
import commonjs from "rollup-plugin-commonjs";
|
|
import json from "rollup-plugin-json";
|
|
import replace from "rollup-plugin-replace";
|
|
import * as path from "path";
|
|
|
|
const external = ["assert"];
|
|
|
|
if (process.env.BUILD_TARGET !== "website") {
|
|
external.push(path.resolve("src/third-party.js"));
|
|
}
|
|
|
|
export default Object.assign(baseConfig, {
|
|
entry: "index.js",
|
|
dest: "dist/index.js",
|
|
format: "cjs",
|
|
plugins: [
|
|
replace({
|
|
"process.env.NODE_ENV": JSON.stringify("production")
|
|
}),
|
|
json(),
|
|
resolve({ preferBuiltins: true }),
|
|
commonjs()
|
|
],
|
|
external,
|
|
paths: {
|
|
[path.resolve("src/third-party.js")]: "./third-party"
|
|
}
|
|
});
|