
Security News
pnpm 10.12 Introduces Global Virtual Store and Expanded Version Catalogs
pnpm 10.12.1 introduces a global virtual store for faster installs and new options for managing dependencies with version catalogs.
Incorporate Select2 JQuery into your ActiveAdmin apps.
Add activeadmin
, jquery-rails
and select2-rails
to your Gemfile:
gem 'activeadmin'
gem 'jquery-rails'
gem 'select2-rails'
And add activeadmin-select2
to your Gemfile:
gem 'activeadmin-select2', github: 'mfairburn/activeadmin-select2'
Add the activeadmin-select2 calls to the active_admin stylesheets and javascripts with:
@import "active_admin/select2/base";
#= require active_admin/select2
Standard :select filters will automagically be converted to Select2 filters. If you want a multi-select combo-box then use:
ActiveAdmin.register Products do
filter :fruits, as: :select2_multiple, collection: [:apples, :bananas, :oranges]
end
To use a Select2 style list simply change from :select to :select2 or :select2_multiple
ActiveAdmin.register Products do
form do |f|
f.input :fruit, as: :select2
end
form do |f|
f.inputs "Product" do
f.has_many :fruits, allow_destroy: true, new_record: "Add Fruit" do |e|
e.input :fruit, as: :select2_multiple
end
end
end
end
Copyright (c) 2014 Mark Fairburn, Praxitar Ltd See the file LICENSE.txt for details.
FAQs
Unknown package
We found that activeadmin-select2 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
pnpm 10.12.1 introduces a global virtual store for faster installs and new options for managing dependencies with version catalogs.
Security News
Amaro 1.0 lays the groundwork for stable TypeScript support in Node.js, bringing official .ts loading closer to reality.
Research
A deceptive PyPI package posing as an Instagram growth tool collects user credentials and sends them to third-party bot services.