Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat(ui): drop moment.js to reduce bundle size #1854

Merged
merged 2 commits into from
Jun 17, 2020
Merged

Conversation

prymitive
Copy link
Owner

No description provided.

@prymitive
Copy link
Owner Author

prymitive commented Jun 17, 2020

Webpack bundle size diff

Total diff: -84.2 KB

M build/static/js/6.cd1b2ba1.chunk.js 544.7 KB 493.1 KB -51.7 KB
M [no source] 12.9 KB 13.3 KB +401 B
M core-js 103.3 KB 103.3 KB +12 B
- moment 57.6 KB -57.6 KB
+ date-fns 5.6 KB +5.6 KB
M build/static/css/15.0a01a1d3.chunk.css 197.4 KB 201.3 KB +3.9 KB
- DarkThemeLoader.scss 104 KB -104 KB
M bootstrap 85.2 KB 85.8 KB +605 B
- DarkTheme.scss 203 B -203 B
- 15.0a01a1d3.chunk.css 35 B -35 B
M Components 5.2 KB 5.2 KB -10 B
M react-input-range 1.5 KB 1.5 KB +15 B
M bootswatch 1.2 KB 1.3 KB +58 B
+ 15.81d34e1b.chunk.css 35 B +35 B
+ LightTheme.scss 174 B +174 B
+ LightThemeLoader.scss 107.3 KB +107.3 KB
+ build/static/css/14.0a01a1d3.chunk.css 197.4 KB +197.4 KB
+ Fonts.scss 7 B +7 B
+ [unmapped] 0 B
+ DarkThemeLoader.scss 104 KB +104 KB
+ bootstrap 85.2 KB +85.2 KB
+ DarkTheme.scss 203 B +203 B
+ Components 5.2 KB +5.2 KB
+ react-input-range 1.5 KB +1.5 KB
+ [sourceMappingURL] 49 B +49 B
+ 14.0a01a1d3.chunk.css 35 B +35 B
+ bootswatch 1.2 KB +1.2 KB
+ [EOLs] 1 B +1 B
M build/static/js/0.443c54a8.chunk.js 21.4 KB 93 KB +71.7 KB
- react-moment 21.2 KB -21.2 KB
M [unmapped] 150 B 163 B +13 B
+ react-popper 3.7 KB +3.7 KB
+ lodash-es 2.2 KB +2.2 KB
+ babel-preset-react-app 372 B +372 B
+ react-fast-compare 1.6 KB +1.6 KB
+ body-scroll-lock 2.4 KB +2.4 KB
+ hotkeys-js 5.1 KB +5.1 KB
+ [no source] 1.4 KB +1.4 KB
+ @babel 134 B +134 B
+ ../../dist-src 378 B +378 B
+ @popperjs 17.2 KB +17.2 KB
+ react-resize-detector 5.4 KB +5.4 KB
+ warning 32 B +32 B
+ @FortAwesome 4 KB +4 KB
+ react-reveal 34.7 KB +34.7 KB
+ react-transition-group 6 KB +6 KB
+ raf-schd 256 B +256 B
+ resize-observer-polyfill 7.5 KB +7.5 KB
+ dom-helpers 612 B +612 B
M build/static/js/2.87c6b880.chunk.js 52.5 KB 88.5 KB +36 KB
- paginator 797 B -797 B
- react-js-pagination 9.1 KB -9.1 KB
M [unmapped] 163 B 90 B -73 B
M [no source] 839 B 695 B -144 B
- tlds 14.2 KB -14.2 KB
- react-linkify 2.5 KB -2.5 KB
- copy-to-clipboard 1.7 KB -1.7 KB
- classnames 446 B -446 B
M @FortAwesome 11.9 KB 563 B -11.3 KB
- uc.micro 2.1 KB -2.1 KB
- toggle-selection 408 B -408 B
- linkify-it 8.4 KB -8.4 KB
M [EOLs] 2 B 1 B -1 B
+ memoize-one 311 B +311 B
+ @babel 108 B +108 B
+ @emotion 15.7 KB +15.7 KB
+ react-select 66 KB +66 KB
+ react-input-autosize 5.1 KB +5.1 KB
M build/static/js/8.ab578671.chunk.js 47 KB 63.2 KB +16.2 KB
M [no source] 11.4 KB 2.1 KB -9.3 KB
- react-json-pretty 3.7 KB -3.7 KB
M ../../src 26.3 KB 4.7 KB -21.6 KB
M @FortAwesome 5.5 KB 5.5 KB -34 B
+ react-autosuggest 39.9 KB +39.9 KB
+ shallow-equal 156 B +156 B
+ create-react-class 5 KB +5 KB
+ section-iterator 1021 B +1021 B
+ react-highlighter 2.5 KB +2.5 KB
+ blacklist 173 B +173 B
+ escape-string-regexp 143 B +143 B
+ react-themeable 1.5 KB +1.5 KB
+ fbjs 361 B +361 B
M build/static/js/1.e11058df.chunk.js 93 KB 61.5 KB -31.5 KB
- react-popper 3.7 KB -3.7 KB
- lodash-es 2.2 KB -2.2 KB
- babel-preset-react-app 372 B -372 B
- react-fast-compare 1.6 KB -1.6 KB
- body-scroll-lock 2.4 KB -2.4 KB
- hotkeys-js 5.1 KB -5.1 KB
M [no source] 1.4 KB 1 KB -318 B
- @babel 134 B -134 B
- ../../dist-src 378 B -378 B
- @popperjs 17.2 KB -17.2 KB
- react-resize-detector 5.4 KB -5.4 KB
- warning 32 B -32 B
M @FortAwesome 4 KB 11.9 KB +7.9 KB
- react-reveal 34.7 KB -34.7 KB
- react-transition-group 6 KB -6 KB
- raf-schd 256 B -256 B
- resize-observer-polyfill 7.5 KB -7.5 KB
- dom-helpers 612 B -612 B
+ date-fns 8.8 KB +8.8 KB
+ paginator 797 B +797 B
+ react-js-pagination 9.1 KB +9.1 KB
+ tlds 14.2 KB +14.2 KB
+ react-linkify 2.5 KB +2.5 KB
+ copy-to-clipboard 1.7 KB +1.7 KB
+ classnames 446 B +446 B
+ uc.micro 2.1 KB +2.1 KB
+ toggle-selection 408 B +408 B
+ linkify-it 8.4 KB +8.4 KB
M build/static/js/7.19bc39d5.chunk.js 63.2 KB 47.2 KB -16 KB
- react-autosuggest 39.9 KB -39.9 KB
- shallow-equal 156 B -156 B
M ../../src 4.7 KB 26.3 KB +21.6 KB
M [no source] 2.1 KB 11.5 KB +9.4 KB
- create-react-class 5 KB -5 KB
- section-iterator 1021 B -1021 B
- react-highlighter 2.5 KB -2.5 KB
- blacklist 173 B -173 B
- escape-string-regexp 143 B -143 B
M @FortAwesome 5.5 KB 5.5 KB +34 B
- react-themeable 1.5 KB -1.5 KB
- fbjs 361 B -361 B
+ date-fns 168 B +168 B
+ react-json-pretty 3.7 KB +3.7 KB
M build/static/js/12.66119985.chunk.js 47.2 KB 33.7 KB -13.5 KB
- Components/Grid/AlertGrid/AlertGroup/Annotation 1.3 KB -1.3 KB
- Components/SilenceModal/SilenceMatch 3.8 KB -3.8 KB
M [no source] 2.1 KB 1.2 KB -904 B
- Components/LabelSetList 1.1 KB -1.1 KB
- Components/SilenceModal/AlertManagerInput 992 B -992 B
- Components/SilenceModal/Browser 3 KB -3 KB
- Components/Labels/FilteringCounterBadge 758 B -758 B
- Components/SilenceModal/DateTimeSelect 7.6 KB -7.6 KB
- Models 2.2 KB -2.2 KB
- Components/SilenceModal/SilencePreview 1.4 KB -1.4 KB
- Components/ManagedSilence 10.4 KB -10.4 KB
M [unmapped] 91 B 178 B +87 B
- Components/Pagination 1.1 KB -1.1 KB
- Components/SilenceModal/SilenceSubmit 2.1 KB -2.1 KB
- Components/SilenceModal 5.5 KB -5.5 KB
- Components/Labels/StaticLabel 316 B -316 B
M Components/Modal 255 B 1.1 KB +856 B
M Common 471 B 1.2 KB +762 B
- Components/ToggleIcon 274 B -274 B
M Hooks 2.2 KB 2.5 KB +359 B
- Components/SilenceModal/PayloadPreview 195 B -195 B
- Components/ValidationError 137 B -137 B
+ Components/Grid/AlertGrid/AlertGroup 4 KB +4 KB
+ Components/Grid/AlertGrid/AlertGroup/GroupFooter 1.3 KB +1.3 KB
+ Components/AlertAck 2.6 KB +2.6 KB
+ Components/Grid/ReloadNeeded 663 B +663 B
+ Components/Grid/EmptyGrid 143 B +143 B
+ Components/Grid/UpstreamError 311 B +311 B
+ Components/Labels 871 B +871 B
+ Components/Animations/DropdownSlide 208 B +208 B
+ Components/Grid/UpgradeNeeded 614 B +614 B
+ Components/CenteredMessage 252 B +252 B
+ Components/Grid/AlertGrid 4.8 KB +4.8 KB
+ Components/Grid 917 B +917 B
+ Components/Grid/AlertGrid/AlertGroup/Alert 4.2 KB +4.2 KB
+ Components/Grid/AlertGrid/AlertGroup/GroupHeader 3.7 KB +3.7 KB
+ Components/Grid/FatalError 338 B +338 B
+ Components/FetchPauser 215 B +215 B
+ Components/TooltipWrapper 1.3 KB +1.3 KB
+ Components/Labels/FilteringLabel 615 B +615 B
+ Components/Animations/MountModal 441 B +441 B
M build/static/js/9.1819bf18.chunk.js 54.9 KB 30.3 KB -24.6 KB
- Components/Grid/AlertGrid/AlertGroup/Annotation 1.3 KB -1.3 KB
M [no source] 2.8 KB 12.8 KB +10 KB
- Components/LabelSetList 1.1 KB -1.1 KB
- Components/Grid/AlertGrid/AlertGroup 4 KB -4 KB
- Components/Grid/AlertGrid/AlertGroup/GroupFooter 1.3 KB -1.3 KB
- Components/AlertAck 2.6 KB -2.6 KB
- Components/Labels/FilteringCounterBadge 758 B -758 B
- Components/Grid/ReloadNeeded 663 B -663 B
- Models 2 KB -2 KB
- Components/Grid/EmptyGrid 143 B -143 B
- Components/ManagedSilence 10.4 KB -10.4 KB
- Components/Grid/UpstreamError 311 B -311 B
- Components/Labels/StaticLabel 316 B -316 B
- Components/Pagination 1.1 KB -1.1 KB
M [unmapped] 90 B 78 B -12 B
- Components/Modal 1.1 KB -1.1 KB
- Components/Labels 871 B -871 B
- Components/Animations/DropdownSlide 208 B -208 B
- Components/Grid/UpgradeNeeded 614 B -614 B
- Components/CenteredMessage 252 B -252 B
- Common 1.5 KB -1.5 KB
- Components/Grid/AlertGrid 4.8 KB -4.8 KB
- Components/Grid 917 B -917 B
- Components/ToggleIcon 274 B -274 B
- Components/Grid/AlertGrid/AlertGroup/Alert 4.2 KB -4.2 KB
- Components/Grid/AlertGrid/AlertGroup/GroupHeader 3.7 KB -3.7 KB
- Components/Grid/FatalError 338 B -338 B
- Hooks 4.7 KB -4.7 KB
- Components/FetchPauser 215 B -215 B
- Components/TooltipWrapper 1.3 KB -1.3 KB
- Components/Labels/FilteringLabel 615 B -615 B
- Components/Animations/MountModal 441 B -441 B
+ ../../../src/js 13 B +13 B
+ ../../../../src/js/utils 469 B +469 B
+ @FortAwesome 683 B +683 B
+ lodash.debounce 1.6 KB +1.6 KB
+ autobind-decorator 1 KB +1 KB
+ ../../../../src/js/input-range 13.6 KB +13.6 KB
M build/static/js/16.8002fc89.chunk.js 211 B 26 KB +25.8 KB
- Styles 49 B -49 B
M [no source] 25 B 692 B +667 B
+ Components/SilenceModal/SilenceSubmit 2.1 KB +2.1 KB
+ Components/SilenceModal/DateTimeSelect 7.5 KB +7.5 KB
+ Components/SilenceModal 5.5 KB +5.5 KB
+ Components/Modal 255 B +255 B
+ Components/SilenceModal/SilenceMatch 3.8 KB +3.8 KB
+ Models 197 B +197 B
+ Components/SilenceModal/AlertManagerInput 992 B +992 B
+ Components/SilenceModal/SilencePreview 1.4 KB +1.4 KB
+ Components/SilenceModal/PayloadPreview 195 B +195 B
+ Common 163 B +163 B
+ Components/ValidationError 137 B +137 B
+ Components/SilenceModal/Browser 3 KB +3 KB
M build/static/js/11.7ae24b59.chunk.js 16.5 KB 23.3 KB +6.8 KB
- bricks.js 2.6 KB -2.6 KB
M [no source] 412 B 1.3 KB +907 B
- fontfaceobserver 4.1 KB -4.1 KB
- @FortAwesome 7.6 KB -7.6 KB
M [unmapped] 91 B 178 B +87 B
- lodash.debounce 1.6 KB -1.6 KB
+ Components/NavBar 2.1 KB +2.1 KB
+ Components/Labels/FilterInputLabel 1.3 KB +1.3 KB
+ Components/SilenceModal 1.1 KB +1.1 KB
+ Components/OverviewModal 948 B +948 B
+ Components/Modal 1.1 KB +1.1 KB
+ Components/NavBar/FetchIndicator 681 B +681 B
+ Hooks 2.2 KB +2.2 KB
+ Components/Labels 871 B +871 B
+ Components/TooltipWrapper 1.3 KB +1.3 KB
+ Components/Animations/DropdownSlide 208 B +208 B
+ Components/Labels/HistoryLabel 308 B +308 B
+ Components/MainModal 980 B +980 B
+ Components/InlineEdit 711 B +711 B
+ Common 1.2 KB +1.2 KB
+ Components/NavBar/FilterInput 6.4 KB +6.4 KB
+ Components/Animations/MountModal 441 B +441 B
M build/static/js/3.11f7f2a0.chunk.js 88.5 KB 21.9 KB -66.7 KB
- memoize-one 311 B -311 B
M [no source] 695 B 1.5 KB +873 B
- @babel 108 B -108 B
- @emotion 15.7 KB -15.7 KB
- @FortAwesome 563 B -563 B
- react-select 66 KB -66 KB
- react-input-autosize 5.1 KB -5.1 KB
+ Components/ToggleIcon 274 B +274 B
+ Components/Grid/AlertGrid/AlertGroup/Annotation 1.3 KB +1.3 KB
+ Models 2 KB +2 KB
+ Hooks 2.2 KB +2.2 KB
+ Components/LabelSetList 1.1 KB +1.1 KB
+ Components/ManagedSilence 10.5 KB +10.5 KB
+ Components/DateFromNow 451 B +451 B
+ Common 308 B +308 B
+ Components/Labels/StaticLabel 316 B +316 B
+ Components/Labels/FilteringCounterBadge 758 B +758 B
+ Components/Pagination 1.1 KB +1.1 KB
M build/static/js/13.05fecb7f.chunk.js 23.3 KB 20.3 KB -3 KB
- Components/NavBar 2.1 KB -2.1 KB
- Components/Labels/FilterInputLabel 1.3 KB -1.3 KB
- Components/SilenceModal 1.1 KB -1.1 KB
- Components/OverviewModal 948 B -948 B
M Components/Modal 1.1 KB 255 B -856 B
- Components/NavBar/FetchIndicator 681 B -681 B
- Hooks 2.2 KB -2.2 KB
- Components/Labels 871 B -871 B
- Components/TooltipWrapper 1.3 KB -1.3 KB
- Components/Animations/DropdownSlide 208 B -208 B
- Components/Labels/HistoryLabel 308 B -308 B
M Components/MainModal 981 B 9.6 KB +8.6 KB
M [unmapped] 178 B 91 B -87 B
M [no source] 1.3 KB 383 B -936 B
- Components/InlineEdit 711 B -711 B
M Common 1.2 KB 163 B -1 KB
- Components/NavBar/FilterInput 6.4 KB -6.4 KB
- Components/Animations/MountModal 441 B -441 B
+ Components/ToggleIcon 274 B +274 B
+ Components/MainModal/Configuration 8.9 KB +8.9 KB
+ Components/Accordion 649 B +649 B
M build/static/js/10.3f9be7f7.chunk.js 30.3 KB 16.6 KB -13.6 KB
M [no source] 12.8 KB 445 B -12.3 KB
- ../../../src/js 13 B -13 B
- ../../../../src/js/utils 469 B -469 B
M @FortAwesome 683 B 7.6 KB +6.9 KB
M [unmapped] 79 B 91 B +12 B
- autobind-decorator 1 KB -1 KB
- ../../../../src/js/input-range 13.6 KB -13.6 KB
+ date-fns 155 B +155 B
+ bricks.js 2.6 KB +2.6 KB
+ fontfaceobserver 4.1 KB +4.1 KB
+ build/static/css/10.a23f2b9e.chunk.css 11 KB +11 KB
+ _tools.scss 10.6 KB +10.6 KB
+ [sourceMappingURL] 49 B +49 B
+ csshake-slow.scss 164 B +164 B
+ [unmapped] 191 B +191 B
+ [EOLs] 8 B +8 B
+ build/static/css/7.c6231af7.chunk.css 4 KB +4 KB
+ [sourceMappingURL] 48 B +48 B
+ style.css 3.9 KB +3.9 KB
+ [unmapped] 0 B
+ [EOLs] 1 B +1 B
M build/static/js/14.5f07d433.chunk.js 20.3 KB 211 B -20.1 KB
- Components/ToggleIcon 274 B -274 B
- Components/MainModal 9.6 KB -9.6 KB
- Components/Modal 255 B -255 B
M [no source] 383 B 25 B -358 B
- Components/MainModal/Configuration 8.9 KB -8.9 KB
- Common 163 B -163 B
- Components/Accordion 649 B -649 B
+ Styles 49 B +49 B
- build/static/css/11.ca163bd3.chunk.css 11.1 KB -11.1 KB
- _tools.scss 10.7 KB -10.7 KB
- [sourceMappingURL] 49 B -49 B
- csshake-slow.scss 164 B -164 B
- [unmapped] 191 B -191 B
- [EOLs] 8 B -8 B
- build/static/css/16.81d34e1b.chunk.css 201.3 KB -201.3 KB
- Fonts.scss 7 B -7 B
- 16.81d34e1b.chunk.css 35 B -35 B
+ [unmapped] 0 B
- bootstrap 85.8 KB -85.8 KB
- LightThemeLoader.scss 107.3 KB -107.3 KB
- Components 5.2 KB -5.2 KB
- react-input-range 1.5 KB -1.5 KB
- LightTheme.scss 174 B -174 B
- [sourceMappingURL] 49 B -49 B
- bootswatch 1.3 KB -1.3 KB
- [EOLs] 1 B -1 B
- build/static/css/8.c6231af7.chunk.css 4 KB -4 KB
- [sourceMappingURL] 48 B -48 B
- style.css 3.9 KB -3.9 KB
+ [unmapped] 0 B
- [EOLs] 1 B -1 B

@prymitive prymitive merged commit 1500705 into master Jun 17, 2020
@prymitive prymitive deleted the drop-momentjs branch June 17, 2020 17:57
@github-actions github-actions bot locked as resolved and limited conversation to collaborators Dec 13, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant