Web applications RequireJS如何与Joomla这样的系统一起使用?
这是一个理论问题 RequireJS如何与具有目录结构的Joomla这样的系统一起使用(包括包含来自组件、插件等的脚本的能力)Web applications RequireJS如何与Joomla这样的系统一起使用?,web-applications,joomla,requirejs,Web Applications,Joomla,Requirejs,这是一个理论问题 RequireJS如何与具有目录结构的Joomla这样的系统一起使用(包括包含来自组件、插件等的脚本的能力) 或者RequireJS不适合这种多层目录结构吗?您可以使用路径配置: require.config({ baseUrl: '/components' paths: { something: 'com_something/script', other: 'com_other/script' } }); require(['something/
或者RequireJS不适合这种多层目录结构吗?您可以使用路径配置:
require.config({
baseUrl: '/components'
paths: {
something: 'com_something/script',
other: 'com_other/script'
}
});
require(['something/a', 'other/b'], function(a, b){
// ...
});
您可以使用路径配置:
require.config({
baseUrl: '/components'
paths: {
something: 'com_something/script',
other: 'com_other/script'
}
});
require(['something/a', 'other/b'], function(a, b){
// ...
});