File tree Expand file tree Collapse file tree 2 files changed +31
-1
lines changed Expand file tree Collapse file tree 2 files changed +31
-1
lines changed Original file line number Diff line number Diff line change @@ -142,7 +142,10 @@ function getMainBundleInfo() {
142142 '' ,
143143 constants . partialBundlePaths . map ( makeBundleHeaderInfo ) . join ( '\n' ) ,
144144 '' ,
145- 'Starting in `v1.39.0`, each plotly.js partial bundle has a corresponding npm package with no dependencies.'
145+ 'Starting in `v1.39.0`, each plotly.js partial bundle has a corresponding npm package with no dependencies.' ,
146+ '' ,
147+ 'Starting in `v1.50.0`, the minified version of each partial bundle is also published to npm in a separate "dist min" package.' ,
148+ ''
146149 ] ;
147150}
148151
@@ -209,6 +212,13 @@ function makeBundleInfo(pathObj) {
209212 'var Plotly = require(\'' + pkgName + '\');' ,
210213 '```' ,
211214 '' ,
215+ '#### dist min npm package (starting in `v1.50.0`)' ,
216+ '' ,
217+ 'Install [`' + pkgName + '-min`](https://www.npmjs.com/package/' + pkgName + '-min) with' ,
218+ '```' ,
219+ 'npm install ' + pkgName + '-min' ,
220+ '```' ,
221+ '' ,
212222 '#### Other plotly.js entry points' ,
213223 '' ,
214224 '| Flavor | Location |' ,
Original file line number Diff line number Diff line change @@ -41,6 +41,26 @@ constants.partialBundlePaths
4141 } ] )
4242 . forEach ( syncPartialBundlePkg ) ;
4343
44+ // sync "minified partial bundle" packages
45+ constants . partialBundlePaths
46+ . map ( function ( d ) {
47+ return {
48+ name : 'plotly.js-' + d . name + '-dist-min' ,
49+ index : d . index ,
50+ main : 'plotly-' + d . name + '.min.js' ,
51+ dist : d . distMin ,
52+ desc : 'Ready-to-use minified plotly.js ' + d . name + ' distributed bundle.' ,
53+ } ;
54+ } )
55+ . concat ( [ {
56+ name : 'plotly.js-dist-min' ,
57+ index : path . join ( constants . pathToLib , 'index.js' ) ,
58+ main : 'plotly.min.js' ,
59+ dist : constants . pathToPlotlyDistMin ,
60+ desc : 'Ready-to-use minified plotly.js distributed bundle.' ,
61+ } ] )
62+ . forEach ( syncPartialBundlePkg ) ;
63+
4464// sync "locales" package
4565syncLocalesPkg ( {
4666 name : 'plotly.js-locales' ,
You can’t perform that action at this time.
0 commit comments