Skip to content

Support sprockets #36

Closed
Closed
@jacob-carlborg-apoex

Description

@jacob-carlborg-apoex

I have a Rails application that was upgraded from Rails 7 to Rails 8 and uses Sprockets as the asset pipeline. When I just add hotwire-spark to the Gemfile I get the following error after bundling and restarting the Rails sever:

Asset `hotwire_spark.js` was not declared to be precompiled in production.
Declare links to your assets in `app/assets/config/manifest.js`.
  //= link hotwire_spark.js
and restart your server

I followed the instructions and thought everything would be fine. But that won't work in the test or production environment when the gem is only added to the development group in the Gemfile.

Is this gem not compatible with Sprockets?

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions