Skip to content

Commit dc722dd

Browse files
author
Per Liedman
committed
Use derequire to make dist file work with browserify
1 parent 7211c1b commit dc722dd

File tree

2 files changed

+8
-6
lines changed

2 files changed

+8
-6
lines changed

Gruntfile.js

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,8 @@ module.exports = function(grunt) {
77
dest: 'dist/leaflet-routing-machine.js',
88
options: {
99
browserifyOptions: {
10-
transform: 'browserify-shim',
10+
transform: ['browserify-shim'],
11+
plugin: ['browserify-derequire'],
1112
standalone: 'L.Routing'
1213
},
1314
banner: '/*! <%= pkg.name %> - v<%= pkg.version %> - ' +

package.json

Lines changed: 6 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -35,16 +35,17 @@
3535
"main": "./dist/leaflet-routing-machine.js",
3636
"devDependencies": {
3737
"browserify": "^13.1.0",
38+
"browserify-derequire": "^0.9.4",
3839
"browserify-shim": "^3.7.0",
40+
"corslite": "0.0.7",
41+
"derequire": "^2.0.3",
3942
"grunt": "^1.0.1",
4043
"grunt-browserify": "^5.0.0",
4144
"grunt-contrib-copy": "^1.0.0",
4245
"grunt-contrib-uglify": "^2.0.0",
4346
"grunt-gh-pages": "^2.0.0",
44-
"grunt-semantic-release": "^0.2.1"
45-
},
46-
"dependencies": {
47-
"corslite": "0.0.7",
47+
"grunt-semantic-release": "^0.2.1",
4848
"polyline": "0.2.0"
49-
}
49+
},
50+
"dependencies": {}
5051
}

0 commit comments

Comments
 (0)