Shoelace::Rails::Ui
Get started with Shoelace today, the Rails way!
What this gem gives you
- Out-of-the-box shoelace
sl_my_component(my_attribute:"")-style ERB syntax for composing HTML with these componentssl_formhelpers to write forms the Rails way, supercharged with Shoelace
- authored originally by @yuki24 in shoelace-rails
Usage
- Add to gemfile and
bundle install rails g shoelace:install- presto!
Requirements
- Rails 7.0 or greater with defaults (hotwire, importmaps, etc.)
Not required
- custom javascript
- custom css
- yarn
- webpack
- node
Docs
All components Example rails application
UPNEXT: gem load right in ci; get push; test against another rails app from gem push; practice demo; tidy up the readme
Workload for MVP (contribute today!)
| Todo | Status |
|---|---|
rails generate shoelace:install one-step to shoelace |
✅ |
| Render nested shoelace components | ✅ |
| Include assets | ✅ |
| V1 codegen | ✅ |
| V2 codegen (with @kddnewton's guidance implemented) | 🔲 |
| Basic gen test coverage | 🔲 |
| All components test covered | 🔲 |
| Github Action CI | ✅ |
| Render icons | 🔲 |
| Autogen docs site | 🔲 |
| Version parity with shoelace | 🔲 |
| BUG - double text render | ✅ |
Notes
Codegen could be generated by a scrape online instead of a full pull. ( Alernatively, unpkg )
License
The gem is available as open source under the terms of the MIT License.