mirror of
https://github.com/Leaflet/Leaflet.git
synced 2025-08-03 15:40:43 +00:00

* Update rollup-plugin-git-version to ^0.3.1 * Update uglify-js to ^3.9.2 * Update git-rev-sync to ^2.0.0 * Update ssri to ^8.0.0 * Update rollup to ^0.59.4 (latests version with support of IE 8) Remove Object.freeze hack, use rollup's `output.freeze` option instead * Update eslint to ^5.16.0 And fix a couple of warnings. Ref: https://eslint.org/docs/user-guide/migrating-to-5.0.0#eslint-recommended-changes https://eslint.org/docs/user-guide/migrating-to-5.0.0#deprecated-globals * Update eslint to ^6.8.0 Ref: https://eslint.org/docs/user-guide/migrating-to-6.0.0#eslint-recommended-changes
31 lines
805 B
JavaScript
31 lines
805 B
JavaScript
// Config file for running Rollup in "watch" mode
|
|
// This adds a sanity check to help ourselves to run 'rollup -w' as needed.
|
|
|
|
import rollupGitVersion from 'rollup-plugin-git-version'
|
|
import gitRev from 'git-rev-sync'
|
|
|
|
const branch = gitRev.branch();
|
|
const rev = gitRev.short();
|
|
const version = require('../package.json').version + '+' + branch + '.' + rev;
|
|
const banner = `/* @preserve
|
|
* Leaflet ${version}, a JS library for interactive maps. http://leafletjs.com
|
|
* (c) 2010-2019 Vladimir Agafonkin, (c) 2010-2011 CloudMade
|
|
*/
|
|
`;
|
|
|
|
export default {
|
|
input: 'src/Leaflet.js',
|
|
output: {
|
|
file: 'dist/leaflet-src.js',
|
|
format: 'umd',
|
|
name: 'L',
|
|
banner: banner,
|
|
sourcemap: true,
|
|
legacy: true, // Needed to create files loadable by IE8
|
|
freeze: false,
|
|
},
|
|
plugins: [
|
|
rollupGitVersion()
|
|
]
|
|
};
|