Description:
Remove "requires" from modules-debug.js
The minification process does not read the "requires" parameters defined
in "modules-debug.js". This parameter should be defined in each custom
yui object that uses some kind of internal or external requirement. The
sole use of "all-app-debug.js" is to define the fullpath of the file
that defines a given module.
This patch removes all the existing "requires" properties from
"modules-debug.js" and add then where they are needed.
Index: app/modules-debug.js
=== modified file 'app/modules-debug.js'
--- app/modules-debug.js 2012-11-15 15:44:00 +0000
+++ app/modules-debug.js 2012-11-20 16:55:43 +0000
@@ -1,6 +1,8 @@
// This file is used for development only. In order to use it you should
call
// the "make debug" command. This command passes the "debug" argument to
the
-// "lib/server.js".
+// "lib/server.js". The sole use of this file is to define the "aliases"
("use"
+// property) and the "fullpath" of the file that implement a given module.
The
+// "requires" property should not be used here.
var GlobalConfig = {
filter: 'debug',
// Set "true" for verbose logging of YUI
@@ -93,19 +95,15 @@
},
Reviewers: mp+135198_ code.launchpad. net,
Message:
Please take a look.
Description:
Remove "requires" from modules-debug.js
The minification process does not read the "requires" parameters defined
in "modules-debug.js". This parameter should be defined in each custom
yui object that uses some kind of internal or external requirement. The
sole use of "all-app-debug.js" is to define the fullpath of the file
that defines a given module.
This patch removes all the existing "requires" properties from
"modules-debug.js" and add then where they are needed.
https:/ /code.launchpad .net/~tveronezi /juju-gui/ change- requires- param/+ merge/135198
(do not edit description out of merge proposal)
Please review this at https:/ /codereview. appspot. com/6856070/
Affected files: models. js debug.js
A [revision details]
M app/app.js
M app/models/charm.js
M app/models/
M app/modules-
M app/store/charm.js
Index: [revision details]
=== added file '[revision details]'
--- [revision details] 2012-01-01 00:00:00 +0000
+++ [revision details] 2012-01-01 00:00:00 +0000
@@ -0,0 +1,2 @@
+Old revision: <email address hidden>
+New revision: <email address hidden>
Index: app/app.js juju-models' , juju-controller s', charm-search' ,
=== modified file 'app/app.js'
--- app/app.js 2012-11-20 14:51:46 +0000
+++ app/app.js 2012-11-20 16:55:43 +0000
@@ -746,6 +746,7 @@
'
'juju-views',
'
+ 'juju-view-
'io',
'json-parse',
'app-base',
Index: app/modules- debug.js debug.js' debug.js 2012-11-15 15:44:00 +0000 debug.js 2012-11-20 16:55:43 +0000
=== modified file 'app/modules-
--- app/modules-
+++ app/modules-
@@ -1,6 +1,8 @@
// This file is used for development only. In order to use it you should
call
// the "make debug" command. This command passes the "debug" argument to
the
-// "lib/server.js".
+// "lib/server.js". The sole use of this file is to define the "aliases"
("use"
+// property) and the "fullpath" of the file that implement a given module.
The
+// "requires" property should not be used here.
var GlobalConfig = {
filter: 'debug',
// Set "true" for verbose logging of YUI
@@ -93,19 +95,15 @@
},
- requires: ['juju-charm-id'],
},
- requires: [
- 'model', 'model-list', 'juju-endpoints', 'juju-charm-
},
// Connectivity
'juju- env': { websocket' ],
fullpath: '/juju- ui/store/ env.js'
- requires: ['reconnecting-
},
@@ -114,7 +112,6 @@
},
- requires: ['juju-charm-id'],
},
@@ -125,13 +122,7 @@
// App
'juju- gui': { charm-search'
- fullpath: '/juju-ui/app.js',
- requires: [
- 'juju-controllers',
- 'juju-views',
- 'juju-models',
- 'juju-view-
- ]
+ fullpath: '/juju-ui/app.js'
}
}
}
Index: app/models/charm.js charm.js'
=== modified file 'app/models/
--- app/models/charm.js 2012-10-29 11:20:31 +0000
+++ app/models/charm.js 2012-11-20 16:55:43 +0000
@@ -226,6 +226,7 @@
}, '0.1.0', {
requires: [
'model',
- 'model-list'
+ 'model-list',
+ 'juju-charm-id'
]
});
Index: app/models/ models. js models. js' models. js 2012-11-16 08:25:02 +0000 models. js 2012-11-20 16:55:43 +0000 datasource- jsonschema' , juju-view- utils', juju-charm- models'
=== modified file 'app/models/
--- app/models/
+++ app/models/
@@ -487,6 +487,7 @@
'
'io-base',
'json-parse',
+ 'juju-endpoints',
'
'
]
Index: app/store/charm.js charm.js'
=== modified file 'app/store/
--- app/store/charm.js 2012-11-05 21:24:42 +0000
+++ app/store/charm.js 2012-11-20 16:55:43 +0000
@@ -114,6 +114,7 @@
}, '0.1.0', { datasource- io',
requires: [
+ 'juju-charm-id',
'
'json-parse'
]