0

I have a dojo application which uses wirejs for dependency injection.
When I try to build the application, I'm getting dependency errors on the 'when' and 'meld' modules. Like the following :

error(311) Missing dependency. module: wire/dojo/events; dependency: when  
error(311) Missing dependency. module: wire/dojo/pubsub; dependency: meld  
error(311) Missing dependency. module: wire/dom/render; dependency: when  
error(311) Missing dependency. module: wire/lib/plugin-base/dom; dependency: when  

My dojo build profile's relevant parts are as follows :

var packagesDir = 'web-app/js/packages',
profile = {
    defaultConfig: {
        hasCache:{
            "dojo-built": 1,
            "dojo-loader": 1,
            "dom": 1,
            "host-browser": 1,
            "config-selectorEngine": "lite",
            "config-tlmSiblingOfDojo":0
        },
        async: 1
    },


    packages : [ 
         {
             name : 'app',
             location : packagesDir + '/app'
         },{
             name : 'dojo',
             location : packagesDir + '/dojo'
         },{
             name : 'dijit',
             location : packagesDir + '/dijit'
         },{
             name : 'dojox',
             location : packagesDir + '/dojox'
         },
         {
             name : 'meld',
             location : packagesDir + '/meld',
             packageJson : {
                dojoBuild : "../../../profiles/meld.profile.js"
             }
         },
         {
             name : 'poly',
             location : packagesDir + '/poly',
             packageJson : {
                dojoBuild : "../../../profiles/poly.profile.js"
             }
         },
         {
             name : 'when',
             location : packagesDir + '/when',
             packageJson : {
                dojoBuild : "../../../profiles/when.profile.js"
             }
         },
         {
             name : 'wire',
             location : packagesDir + '/wire',
             packageJson : {
                dojoBuild : "../../../profiles/wire.profile.js"
             }
         }

Am I missing something here ?

Thanks !

Philippe
  • 6,703
  • 3
  • 30
  • 50
  • I created a github project that reproduces the issue at https://github.com/psoares/DojoAndWirejs. After pulling the project, use npm install to perform a dojo build, and npm start to start a server. The index.html page uses the source javascript. The index-built.html page uses the built modules and has AMD traces enabled. You will notice in the console that module "wire/wire" is not recognized... – Philippe Nov 21 '14 at 17:41
  • Dojo complains when it hits the following statement on wire/wire.js : createContext = require('./lib/context'); It doesn't manage to resolve the module... – Philippe Nov 21 '14 at 21:41

0 Answers0