Grails 2 资源和 yui3 脚本加载器
我想将 yui3 与 grails 2 Web 应用程序一起使用,但 grails 2 处理资源的新方式开始让我烦恼。
yui3 加载js文件时似乎有正确的路径,即../static/js/yui3/node-menunav/node-menunav-min.js,但当它尝试加载依赖项时,我得到的只是404错误。
我如何绕过 js 的资源插件,或者我应该完全关闭资源插件,因为这似乎做了很多工作却没有多少收获。
是的,我知道有一个插件,但它只是 JavaScript,不需要插件,我正在努力将插件的使用量保持在最低限度。
I would like to use yui3 with a grails 2 web application but the new way that grails 2 handles resources is starting to annoy me.
yui3 seems to have the path right when is loads the js files, i.e. ../static/js/yui3/node-menunav/node-menunav-min.js but all I get is 404 errors when it tries to load dependencies.
How do I bypass the resources plugin for js or should I turn of the resources plugin altogether, as it seems a lot of work for not much gain.
And yes I know there is a plugin but it's just JavaScript and doesn't need a plugin and I'm trying to keep the plugin usage to a minimum.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
要么在 BuildConfig.groovy 中注释上面的行:
要么将你的 js 包含在 ApplicationResources.groovy 中。
Either comment the line above in your BuildConfig.groovy:
Or include your js in your ApplicationResources.groovy.