Description
A new engine with Rails 7 alpha 2, generated usingrails plugin new custom_page --mountable --full
generates a new engine that includes the importmap-rails gem in the bundled gems but there is no ability to use it. Adding spec.add_dependency 'importmap-rails'
to gemspec makes no difference. there is no importmap executable in the bin directory.
A call to bundle info importmap-rails
Produces
* importmap-rails (0.8.1)
Summary: Use ESM with importmap to manage modern JavaScript in Rails without transpiling or bundling.
Homepage: https://github.com/rails/importmap-rails
Source Code: https://github.com/rails/importmap-rails
Path: /home/jamie/.rvm/gems/ruby-3.0.0@custom_page/gems/importmap-rails-0.8.1
A call to rails --tasks
lists
rails app:importmap:install # Setup Importmap for the app
I was expecting to see the same without app:
prefix
A call to this task resolves to a template error
rails app:importmap:install
Don't know how to build task 'app:template' (See the list of available tasks with `rails --tasks`)
Did you mean? app:tmp:create
Hope this is a clear enough question for you. If there is a workaround solution to this I'd be grateful to hear it and I'm sure others will too. The reason for me wanting this is that I totally failed to introduced webpacker in a rails 6.1.4 engine and I was hoping this was going to be my, much improved, solution
Cheers
James