[
https://issues.apache.org/jira/browse/WICKET-5610?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]
Martin Grigorov updated WICKET-5610:
------------------------------------
Fix Version/s: (was: 8.0.0)
> Introduce IApplicationSettings.useCdnResources() that will serve jQuery from
> CDN and can be used by 3rd party libs
> ------------------------------------------------------------------------------------------------------------------
>
> Key: WICKET-5610
> URL: https://issues.apache.org/jira/browse/WICKET-5610
> Project: Wicket
> Issue Type: Improvement
> Components: wicket
> Affects Versions: 6.15.0
> Reporter: Hendy Irawan
> Assignee: Martin Grigorov
> Attachments: use-cdn-app.tgz
>
>
> wicket-bootstrap has a
> [IBootstrapSettings.useCdnResources()|https://github.com/l0rdn1kk0n/wicket-bootstrap/blob/bootstrap-parent-0.9.3/bootstrap-core/src/main/java/de/agilecoders/wicket/core/settings/IBootstrapSettings.java]
> which is a great idea.
> Wicket should adopt this setting in core. And when true, Wicket JS libraries
> such as jQuery should use public CDN.
> This setting will default to true on {{DEPLOYMENT}}, and false for
> {{DEVELOPMENT}} (but of course, can be set to true programmatically).
> wicket-bootstrap will then can use CDN settings from wicket core.
> In addition, I would suggest a variant of {{JavaScriptResourceReference}}
> that also has an additional parameter for {{cdnUrl}} (which can be {{String}}
> for convenience or {{Url}} for strictness, up to you), e.g. :
> {code}
> public HowlerJavaScriptReference() {
> super(HowlerJavaScriptReference.class, "howler.js",
> "//cdnjs.cloudflare.com/ajax/libs/howler/1.1.17/howler.min.js");
> }
> {code}
> its behavior will switch based on {{useCdnResources}} setting, and very easy
> and practical to code this way. :)
--
This message was sent by Atlassian JIRA
(v6.4.14#64029)