importmap-rails
importmap-rails copied to clipboard
Use ESM with importmap to manage modern JavaScript in Rails without transpiling or bundling.
```bash $ bin/importmap outdated | Package | Current | Latest | |-----------|---------|--------| | cropperjs | 1.6.1 | 1.6.2 | 1 outdated package found $ bin/importmap update Pinning "cropperjs" to vendor/javascript/cropperjs.js...
In my project (using Rails 7 with importmap-rails) I am trying to import a module which has a complex dependency graph. In particular, two dependencies (let's call them `A` and...
It's currently possible to "manually" add a URL to `config/importmap.rb` that will not attempt to be locally cached e.g. ```ruby # config/importmap.rb pin "some-package", to: "https://someotherhost.com/some-package.js" ``` ...but there isn't...
Would be really cool with a way to 're-sync' the vendor folder with the `importmap.rb` file. For instance doing something like: `bin/ importmaps repin_all`
Maybe I'm missing something, but shouldn't it be possible to have multiple separate importmaps? :) My app has three distinct parts/namespaces ("web" for the public marketing page, "admin" for the...
In rubygems/rubygems.org#4396 we ran into the problem of verifying the provenance of files in vendor/javascript. This is a blocker for us using importmap-rails at this time. In this PR, I...
I implemented the idea mentioned in #240 of allowing multiple importmaps. It was pretty straightforward and so far works great (for my use-case). Instead of having one `Importmap::Map` in `Rails.application.importmap`,...
I don't know how easy it would be to add given how the pins are kept but it would be nice if the outdated packages considered the dependencies of other...
This is not yet ready for review - Related https://github.com/rails/importmap-rails/pull/217#issuecomment-1906044892 - Closes https://github.com/rails/importmap-rails/issues/153 - Closes https://github.com/rails/importmap-rails/issues/91 - Related https://github.com/rails/propshaft/pull/181 ## The main focus The main focus of this PR is...
On 2.0.1 I first list the packages I've pinned: ``` bin/importmap packages video.js 8.6.1 @babel/runtime 7.23.5 @videojs/vhs-utils 4.1.0 @videojs/vhs-utils 3.0.5 @videojs/xhr 2.6.0 @xmldom/xmldom 0.8.10 dom-walk 0.1.2 global 4.4.0 is-function 1.0.2...