Security News
PyPI’s New Archival Feature Closes a Major Security Gap
PyPI now allows maintainers to archive projects, improving security and helping users make informed decisions about their dependencies.
Easiest way to use Heroicons in your Rails application. This project adds a view helper to render the beautiful hand-crafted SVG icons, by the makers of Tailwind CSS. All icons in Heroicons v2.0.11
are supported.
This project has no affiliation with Tailwind Labs. You can check out all icons at Heroicons website.
Add heroicons-rails
to your Gemfile by running:
bundle add heroicons-rails
Or add it manually:
gem "heroicons-rails"
After adding the gem in your Gemfile you can start to use heroicon_tag
helper in your Rails application:
<%= heroicon_tag "plus" %>
Heroicons currently have two sets (solid, outline) and two sizes (20, 24). You can specify them as keyword arguments:
<%= heroicon_tag "plus", variant: :outline, size: 20 %>
This gem defaults the variant to :solid
and size to 24
.
Any additional keyword parameters will be added as HTML attributes of the svg element:
<%= heroicon_tag "plus", class: "w-5 h-5", "data-controller": "disclosure" %>
Will result in:
<svg xmlns="http://www.w3.org/2000/svg" viewbox="0 0 24 24" fill="currentColor" class="w-5 h-5" data-controller="disclosure">
<path fill-rule="evenodd" d="M12 ..." clip-rule="evenodd"></path>
</svg>
Run the tests with ./bin/rails test
.
Heroicons Rails is released under the MIT License.
FAQs
Unknown package
We found that heroicons-rails 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
PyPI now allows maintainers to archive projects, improving security and helping users make informed decisions about their dependencies.
Research
Security News
Malicious npm package postcss-optimizer delivers BeaverTail malware, targeting developer systems; similarities to past campaigns suggest a North Korean connection.
Security News
CISA's KEV data is now on GitHub, offering easier access, API integration, commit history tracking, and automated updates for security teams and researchers.