Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit 0795eb6

Browse files
committed
Merge branch 'master' of github.com:krausest/js-framework-benchmark
2 parents f5d476f + bc2be6c commit 0795eb6

File tree

18 files changed

+1527
-706
lines changed

18 files changed

+1527
-706
lines changed

frameworks/keyed/million/package-lock.json

Lines changed: 74 additions & 210 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

frameworks/keyed/million/package.json

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -5,22 +5,21 @@
55
"build-prod": "rollup -c"
66
},
77
"dependencies": {
8-
"million": "2.0.0"
8+
"million": "2.1.2"
99
},
1010
"devDependencies": {
1111
"@babel/core": "^7.21.0",
1212
"@babel/plugin-transform-react-jsx": "^7.21.0",
1313
"@babel/types": "^7.21.2",
1414
"@rollup/plugin-babel": "^6.0.3",
1515
"@rollup/plugin-node-resolve": "^15.0.1",
16-
"@rollup/plugin-terser": "^0.4.0",
17-
"unplugin": "^1.2.0"
16+
"@rollup/plugin-terser": "^0.4.0"
1817
},
1918
"js-framework-benchmark": {
2019
"frameworkVersionFromPackage": "million",
2120
"frameworkHomeURL": "https://github.com/aidenybai/million",
2221
"issues": [
23-
772, 801
22+
801
2423
]
2524
}
2625
}
Lines changed: 27 additions & 41 deletions
Original file line numberDiff line numberDiff line change
@@ -1,52 +1,38 @@
11
import resolve from '@rollup/plugin-node-resolve';
22
import terser from '@rollup/plugin-terser';
3-
import { babel } from '@rollup/plugin-babel';
4-
import { URL } from 'url';
3+
import million from 'million/compiler';
54

6-
const plugins = [
7-
resolve({
8-
preferBuiltins: false,
9-
extensions: ['.js', '.jsx'],
10-
}),
11-
babel({
12-
plugins: [
13-
[
14-
'@babel/plugin-transform-react-jsx',
15-
{
16-
runtime: 'classic',
17-
pragma: 'h',
18-
},
19-
],
20-
],
21-
}),
22-
terser({
23-
parse: {
24-
ecma: 8,
25-
},
26-
compress: {
27-
ecma: 5,
28-
inline: true,
29-
if_return: false,
30-
reduce_funcs: false,
31-
passes: 5,
32-
comparisons: false,
33-
},
34-
output: {
35-
ecma: 5,
36-
comments: false,
37-
},
38-
toplevel: true,
39-
module: true,
40-
}),
41-
];
5+
const TERSER_OPTIONS = {
6+
compress: {
7+
ecma: 5,
8+
inline: true,
9+
if_return: false,
10+
reduce_funcs: false,
11+
passes: 5,
12+
comparisons: false,
13+
},
14+
toplevel: true,
15+
mangle: true,
16+
module: true,
17+
};
4218

4319
export default {
44-
input: new URL('src/main.jsx', import.meta.url).pathname,
20+
input: 'src/main.jsx',
4521
output: {
4622
name: 'million',
4723
format: 'iife',
48-
file: new URL('dist/main.js', import.meta.url).pathname,
24+
file: 'dist/main.js',
4925
sourcemap: false,
5026
},
51-
plugins,
27+
watch: {
28+
clearScreen: false,
29+
},
30+
plugins: [
31+
resolve({
32+
preferBuiltins: false,
33+
extensions: ['.js', '.jsx'],
34+
}),
35+
million.rollup(),
36+
terser(TERSER_OPTIONS),
37+
],
5238
};

0 commit comments

Comments
 (0)