Code Overview:
main.js:
require.config({
paths: {
'uiBootstrap': '../lib/bootstrap/angular-bootstrap/ui-bootstrap-tpls.min'
},
shim: {***},
priority: ['angular'],
deps: [
'./bootstrap'
]
});
bootstrap.js:
define([
'require',
'angular',
...
], function (require, ng) {
'use strict';
require([
'domReady!',
'uiBootstrap'
], function (document) {
ng.bootstrap(document, ['app']);...
app.js:
define([
'angular',
...
], function (ng) {
'use strict';
return ng.module('app', [
...
'uiBootstrap'
]);
});
I encountered various errors while experimenting with different configurations. After modifying the ui-bootstrap-tpls.min.js file and replacing all instances of ui.bootstrap to uiBootstrap along with adjusting the module name reference as shown above, everything started working smoothly with ui-bootstrap.
This workaround is far from ideal.
If anyone could shed light on why this issue arose and suggest a more suitable resolution, I would greatly appreciate it. I'd like to avoid using this modified version of ui-bootstrap in public.
Thank you!