Closed ravikovour closed 6 years ago
As Grails Asset pipeline is a replacement for Grails Resource Plugin there is no option to achieve 'overrides' feature similar grais resource plugin.
With Grails Resource plugin we can override a module or particular resource of a module.
Plugin-A Resources.groovy
modules = { 'businessModule' { resource url:[plugin: 'pluginA', file: 'js/jquery/jquery-1.7.2.js'] resource url:[plugin: 'pluginA', file: 'js/jquery/jquery-ui-1.8.15.custom.js'] resource id: [plugin: 'pluginA', file: 'js/select2/select2-v1.js'] }
Plugin-B Resources.groovy
modules = { / Override select2.js of the Plugin-A / overrides { 'businessModule' { resource id: [plugin: 'pluginA', file: 'js/select2/select2-v1.js'], url: [file: 'js/select2/select2-v2.js'] } }
you can by simply placing the asset in the master project instead of in the sub project but an override from a plugin no
As Grails Asset pipeline is a replacement for Grails Resource Plugin there is no option to achieve 'overrides' feature similar grais resource plugin.
With Grails Resource plugin we can override a module or particular resource of a module.
Plugin-A Resources.groovy
modules = { 'businessModule' { resource url:[plugin: 'pluginA', file: 'js/jquery/jquery-1.7.2.js'] resource url:[plugin: 'pluginA', file: 'js/jquery/jquery-ui-1.8.15.custom.js'] resource id: [plugin: 'pluginA', file: 'js/select2/select2-v1.js'] }
Plugin-B Resources.groovy
modules = { / Override select2.js of the Plugin-A / overrides { 'businessModule' { resource id: [plugin: 'pluginA', file: 'js/select2/select2-v1.js'], url: [file: 'js/select2/select2-v2.js'] } }