Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Prevent asset_path clashing with route definition in a Rails app
If a Rails app has `resources :assets` configured in `config/routes.rb` and the `config.assets.prefix` setting configured in `config/initializers/assets.rb` to something other than `assets`, use of `asset_path` to locate the `hotwire_spark.js` file will result in an error and the file not being found. Rails provides a solution for this by aliasing `asset_path` with `path_to_asset`. Co-authored-by: Matt Menefee <[email protected]>
- Loading branch information