You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@wicket.apache.org by "Martin Grigorov (JIRA)" <ji...@apache.org> on 2014/07/02 17:00:34 UTC
[jira] [Updated] (WICKET-5610) Introduce
IApplicationSettings.useCdnResources() that will serve jQuery from CDN and
can be used by 3rd party libs
[ https://issues.apache.org/jira/browse/WICKET-5610?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Martin Grigorov updated WICKET-5610:
------------------------------------
Summary: Introduce IApplicationSettings.useCdnResources() that will serve jQuery from CDN and can be used by 3rd party libs (was: Adopt IApplicationSettings.useCdnResources() from wicket-bootstrap)
> 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
>
> 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.2#6252)