fix(bower): export as BpmnJS in bower bundle

This commit is contained in:
Nico Rehwaldt 2014-06-19 17:17:45 +02:00
parent 42284669f1
commit c74b81bba5
1 changed files with 8 additions and 9 deletions

View File

@ -24,7 +24,6 @@ module.exports = function(grunt) {
if (components.indexOf('viewer') >= 0) { if (components.indexOf('viewer') >= 0) {
alias.push('index.js:bpmn-js'); alias.push('index.js:bpmn-js');
alias.push('<%= config.sources %>/Viewer.js:bpmn-js/Viewer');
} }
if (components.indexOf('modeler') >= 0) { if (components.indexOf('modeler') >= 0) {
@ -115,7 +114,7 @@ module.exports = function(grunt) {
watch: { watch: {
files: { files: {
'<%= config.dist %>/bpmn.js': [ '<%= config.sources %>/**/*.js' ], '<%= config.dist %>/bpmn.js': [ '<%= config.sources %>/**/*.js' ],
'<%= config.dist %>/bpmn-viewer.js': [ '<%= config.sources %>/lib/Viewer.js' ] '<%= config.dist %>/bpmn-viewer.js': [ '<%= config.sources %>/Viewer.js' ]
}, },
options: { options: {
watch: true, watch: true,
@ -129,10 +128,14 @@ module.exports = function(grunt) {
}, },
bowerViewer: { bowerViewer: {
files: { files: {
'<%= config.bowerDist %>/bpmn-viewer.js': [ '<%= config.sources %>/lib/Viewer.js' ] '<%= config.bowerDist %>/bpmn-viewer.js': [ '<%= config.sources %>/Viewer.js' ]
}, },
options: { options: {
browserifyOptions: {
builtins: false
},
bundleOptions: { bundleOptions: {
standalone: 'BpmnJS',
detectGlobals: false, detectGlobals: false,
insertGlobalVars: [], insertGlobalVars: [],
debug: false debug: false
@ -147,16 +150,12 @@ module.exports = function(grunt) {
'jquery-mousewheel': '$' 'jquery-mousewheel': '$'
} }
} ] } ]
], ]
alias: bundleAlias([
'viewer',
'libs-local'
])
} }
}, },
standaloneViewer: { standaloneViewer: {
files: { files: {
'<%= config.dist %>/bpmn-viewer.js': [ '<%= config.sources %>/lib/Viewer.js' ] '<%= config.dist %>/bpmn-viewer.js': [ '<%= config.sources %>/Viewer.js' ]
}, },
options: { options: {
alias: bundleAlias([ alias: bundleAlias([