Skip to content

Commit

Permalink
build: rollup.config.js
Browse files Browse the repository at this point in the history
  • Loading branch information
VirgilClyne committed Oct 13, 2024
1 parent a56ffc3 commit 1949e9a
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 2 deletions.
3 changes: 2 additions & 1 deletion rollup.debug.config.js
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
import pkg from './package.json' with { type: "json" };
import json from '@rollup/plugin-json';
import commonjs from "@rollup/plugin-commonjs";
import { nodeResolve } from '@rollup/plugin-node-resolve';
Expand All @@ -8,7 +9,7 @@ export default [
output: {
file: 'dist/request.js',
//format: 'es',
banner: `/* README: https://github.com/NSRingo */\nconsole.log(' iRingo: 📰 News β Request')\nconsole.log('${new Date().toLocaleString('zh-CN', {timeZone: 'PRC'})}')`,
banner: `/* README: https://github.com/NSRingo */\nconsole.log(' iRingo: 📰 News β Request')\nconsole.log('Version: ${pkg.version}')\nconsole.log('${new Date().toLocaleString('zh-CN', {timeZone: 'PRC'})}')`,
},
plugins: [json(), commonjs(), nodeResolve()]
}
Expand Down
3 changes: 2 additions & 1 deletion rollup.default.config.js
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
import pkg from './package.json' with { type: "json" };
import json from '@rollup/plugin-json';
import commonjs from "@rollup/plugin-commonjs";
import terser from '@rollup/plugin-terser';
Expand All @@ -9,7 +10,7 @@ export default [
output: {
file: 'dist/request.js',
format: 'es',
banner: `/* README: https://github.com/NSRingo */\nconsole.log(' iRingo: 📰 News Request')\nconsole.log('${new Date().toLocaleString('zh-CN', {timeZone: 'PRC'})}')`,
banner: `/* README: https://github.com/NSRingo */\nconsole.log(' iRingo: 📰 News Request')\nconsole.log('Version: ${pkg.version}')\nconsole.log('${new Date().toLocaleString('zh-CN', {timeZone: 'PRC'})}')`,
},
plugins: [json(), commonjs(), nodeResolve(), terser()]
}
Expand Down

0 comments on commit 1949e9a

Please sign in to comment.