![Oracle Drags Its Feet in the JavaScript Trademark Dispute](https://cdn.sanity.io/images/cgdhsj6q/production/919c3b22c24f93884c548d60cbb338e819ff2435-1024x1024.webp?w=400&fit=max&auto=format)
Security News
Oracle Drags Its Feet in the JavaScript Trademark Dispute
Oracle seeks to dismiss fraud claims in the JavaScript trademark dispute, delaying the case and avoiding questions about its right to the name.
NOTE: use v0.1.5 to use jquery-ui less then v1.11.0
Add CDN support to
This gem is designed to be used with jquery-rails-cdn
Serving javascripts and stylesheets from a publicly available CDN has clear benefits:
This gem offers the following features:
On top of that, if you're using asset pipeline, you may have noticed that the major chunks of the code in application.js
is jQuery UI. Implications of externalizing jQuery UI from application.js
are:
rake assets:precompile
takes less peak memory usage.Changelog:
force: true
to the tagAdd this line to your application's Gemfile:
gem 'jquery-ui-rails-cdn'
From jquery-ui-rails
4.1.0
onward, Jquery::Ui::Rails::JQUERY_UI_VERSION
is defiend and auto updated on each release.
If you are using version lower than 4.1.0
, you will need to use forked version of jquery-ui-rails
Jquery::Ui::Rails::JQUERY_UI_VERSION
.This gem adds these methods to generate a script tag to the jQuery on a CDN of your preference:
jQuery_ui_include_tag
and jquery_ui_url
If you're using asset pipeline with Rails 3.1+, first remove //= require jquery-ui
(or other special files if you are using not full version) from application.js
.
Then in layout:
= jquery_include_tag :google
= jquery_ui_include_tag :google
= javascript_include_tag 'application'
Note that valid CDN symbols for jQuery and jQuery-UI are:
:google
:microsoft
:jquery
:yandex
Note that valid CDN symbols for bootstrap are:
:default
It will generate the following for jQuery-UI on production:
<script src="//ajax.googleapis.com/ajax/libs/jquery/1.8.4/jquery.min.js" type="text/javascript"></script>
<script type="text/javascript">
//<![CDATA[
window.jQuery || document.write(unescape('%3Cscript src="/assets/jquery-ui-3aaa3fa0b0207a1abcd30555987cd4cc.js" type="text/javascript">%3C/script>'))
//]]>
</script>
on development:
<script src="/assets/jquery.js?body=1" type="text/javascript"></script>
If you want to check the production URL, you can pass :force => true
as an option.
jquery_ui_include_tag :google, :force => true
To fallback to rails assets when CDN is not available, add jquery-ui.js
in config/environments/production.rb
config.assets.precompile += %w( jquery.js jquery-ui.js )
FAQs
Unknown package
We found that jquery-ui-rails-cdn demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Security News
Oracle seeks to dismiss fraud claims in the JavaScript trademark dispute, delaying the case and avoiding questions about its right to the name.
Security News
The Linux Foundation is warning open source developers that compliance with global sanctions is mandatory, highlighting legal risks and restrictions on contributions.
Security News
Maven Central now validates Sigstore signatures, making it easier for developers to verify the provenance of Java packages.