New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Asset Pipeline Gradle in plugin breaks consuming web #60
Comments
A plugin should not use asset pipeline gradle as a build dependency as assets are not processed until app phase Sent from my iPhone
|
I get that but we have a situation where we have plugins that we run as web apps, such as our pattern library, which need both standalone and plugin capabilities. We could split them, but it works great in grails 2.x today. |
We have several nested infrastructures such as: domain -> pattern-libray -> web -> app where domain, pattern library and web are all plugins and the app is the only actual app. We work mainly in web due to it containing shared web functionality. The app only has some small tweaks as there are 16 different app artifacts. Having web run stand alone is important, as is using local plugin references from all the layers (for example). This allows us to change core stuff and see it quickly in the brands without having to solve version/snapshot hell. |
@davydotcom Another question - Is there any reason that the configuration for the plugin is in the build.gradle and not the application.yaml file? The above situation where a plugin can not define the asset-pipeline-gradle can not set properties like es5->es6 level support, minify and compile options, etc. |
The reason is gradle cannot interpret application.yml. Thats grails runtime config where as assets{} is gradle build config |
The reason your app doesn't work when you use that plugin is you've loaded a |
If we can't use asset pipeline gradle in plugins is there another way to specify extra build-time includes? We have a plugin that provides font files in Plugin structure:
We can get around this by moving fonts under one of the default folders (images, javascripts, stylesheets), but it's not ideal. |
this is actually a bug in the grails gradle plugin that has since been fixed are you on the latest grails3 build? |
The project is on |
I would try 10 for sure Sent from my iPhone
|
Still seeing this error with
We also use the artifactory plugin
edit: 3.2.0 of the artifactory plugin hits the same error. We tried excluding org.jfrog.gradle a few different ways but didn't have any luck. Anyone know if we're on the right track? |
what gradle version? |
2.9 |
sure this isn't an artifactory plugin issue? asset-pipeline-gradle does not even reference this plugin |
We're guessing the Bintray and Artifactory plugins aren't getting along but haven't tracked down the root cause yet. For now we moved our fonts under the stylesheets directory. Thanks for the help |
fixed plugin support , added asset-pipeline-gradle to your grails 3 plugin...
|
When a plugin defines the asset-pipeline-gradle build dep, plugin apply and an asset closure inside it's build config - a consuming web application breaks when trying to load local assets (less, css, js). The tag renders with <script... application.js> but without the ?compile=false and asking for the resource directly produces a 404.
In the example below the foo.css asset from the plugin is rendered and the background is green, but the parents level assets of application.js and application.css are not processed. I have tried including the excluding the asset-pipeline-gradle from the web project to no avail. It isn't until the plugin project removes the asset-pipeline-gradle reference that everything works.
Example of the issue using grails 3.0.9 and asset-pipeline 2.6.9.
https://github.com/Grails-Plugin-Consortium/asset-pipeline-bug
Cheers.
The text was updated successfully, but these errors were encountered: