-
Notifications
You must be signed in to change notification settings - Fork 2.3k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
They are useful to use in browser and at least now we may see how big this lib is.
- Loading branch information
Showing
6 changed files
with
286 additions
and
5 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,10 @@ | ||
{ | ||
"presets": ["jason"] | ||
"presets": ["jason"], | ||
"env": { | ||
"esm": { | ||
"presets": [ | ||
["jason", { "modules": false }] | ||
] | ||
} | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,5 @@ | ||
lib/ | ||
dist/ | ||
|
||
# Logs | ||
logs | ||
|
@@ -32,4 +33,4 @@ node_modules | |
.idea | ||
|
||
# Mac OS X | ||
.DS_Store | ||
.DS_Store |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,12 @@ | ||
{ | ||
"./dist/react-big-calendar.js": { | ||
"bundled": 470107, | ||
"minified": 152579, | ||
"gzipped": 42233 | ||
}, | ||
"./dist/react-big-calendar.min.js": { | ||
"bundled": 439313, | ||
"minified": 142681, | ||
"gzipped": 39554 | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,61 @@ | ||
import nodeResolve from 'rollup-plugin-node-resolve' | ||
import babel from 'rollup-plugin-babel' | ||
import commonjs from 'rollup-plugin-commonjs' | ||
import replace from 'rollup-plugin-replace' | ||
import { sizeSnapshot } from 'rollup-plugin-size-snapshot' | ||
import { terser } from 'rollup-plugin-terser' | ||
|
||
const input = './src/index.js' | ||
const name = 'ReactBigCalendar' | ||
const globals = { | ||
react: 'React', | ||
'react-dom': 'ReactDOM', | ||
} | ||
|
||
const babelOptions = { | ||
exclude: /node_modules/, | ||
runtimeHelpers: true, | ||
} | ||
|
||
const commonjsOptions = { | ||
include: /node_modules/, | ||
} | ||
|
||
export default [ | ||
{ | ||
input, | ||
output: { | ||
file: './dist/react-big-calendar.js', | ||
format: 'umd', | ||
name, | ||
globals, | ||
}, | ||
external: Object.keys(globals), | ||
plugins: [ | ||
nodeResolve(), | ||
babel(babelOptions), | ||
commonjs(commonjsOptions), | ||
replace({ 'process.env.NODE_ENV': JSON.stringify('development') }), | ||
sizeSnapshot(), | ||
], | ||
}, | ||
|
||
{ | ||
input, | ||
output: { | ||
file: './dist/react-big-calendar.min.js', | ||
format: 'umd', | ||
name, | ||
globals, | ||
}, | ||
external: Object.keys(globals), | ||
plugins: [ | ||
nodeResolve(), | ||
babel(babelOptions), | ||
commonjs(commonjsOptions), | ||
replace({ 'process.env.NODE_ENV': JSON.stringify('production') }), | ||
sizeSnapshot(), | ||
terser(), | ||
], | ||
}, | ||
] |
Oops, something went wrong.