All Questions
Tagged with ruby-on-rails-7 asset-pipeline
17
questions
1
vote
1
answer
26
views
Sprockets::Rails::Helper::AssetNotPrecompiledError in MyEngine::Frontend#new
Asset hero_banner.jpg was not declared to be precompiled in production.
Declare links to your assets in app/assets/config/manifest.js.
//= link hero_banner.jpg
Rails.application.config.assets.paths &...
1
vote
0
answers
57
views
How to prevent asset compilation for certain assets folders in Rails 7 engine that uses sprockets-rails with the asset pipeline
I am self hosting Tinymce in a Rails 7 engine that uses sprockets_rails
I have downloaded the tinymce code from the tinymce website and added to an app/assets/tinymce folder in the engine
I have the ...
1
vote
1
answer
269
views
Sprockets 4 not loading javascript assets from Rails 7 engine
TL;DR.
Sprockets 4 isn't loading javascript assets properly from a Rails 7 engine.
Project Overview
I am working on a Rails project, which is comprised of a parent-app and engine-app.
Both have ...
0
votes
1
answer
126
views
How to load an Active Storage image into a canvas with a Stimulus controller?
I would like to load the images that users submit into the Stimulus controller so that I can use it within my Three JS (3D JavaScript Library) code. How can I achieve this? I’ve already tried so many ...
0
votes
1
answer
382
views
Rails 7 - React application not loading assets from subdirectory
I recently migrated a React-Rails application from rails 6 to 7. Since Webpacker was discontinued, I tried configuring Webpack on the javascript side.
The rails application is configured to load from ...
1
vote
0
answers
149
views
Rails 7 SassC Error: Bootstrap not found or unreadable while uploading on Heroku
I am upgrading my app from Rails 6.1 to Rails 7.
While testing it on development env., it works fine.
But I encouter an issue while uploading it on heroku.
Heroku raise this error while precompiling ...
0
votes
1
answer
2k
views
ActionView::Template::Error ( The asset "application.css" is not present in the asset pipeline. ) in Rails 7
After shifting from webpacker to importmaps in Rails 7. I keep getting this error no matter what I do to resolve it. Following is the output of the error.
I, [2022-12-02T11:33:16.828698 #2401] INFO --...
1
vote
1
answer
743
views
Sprockets::DoubleLinkError: Multiple files with the same output path cannot be linked ("application.js") in Rails 7
Sprockets::DoubleLinkError: Multiple files with the same output path cannot be linked ("application.js") in Rails 7.
After compiling assets:
Here is my manifest.json:
Directory structure:
1
vote
0
answers
205
views
how to refer to a rails image asset in JSX and Rails 7 (esbuild)
Can't figure out how to get an asset path in JSX that is processed byjsbundling-rails/esbuild:
<img src={`zone_icons/${zone}.png` }/>
I've seen that in the source code of cssbundling-rails ...
1
vote
0
answers
75
views
Adding FullCalendar to React on Rails project causes DoubleLinkError in application.css
I have a React project served using Ruby on Rails 7. It's set up using this tutorial (source code available here); I'm at the part where you add React Router so you can add a second page to the app.
I ...
3
votes
0
answers
540
views
In Rails 7 with esbuild build, how do I run a script of esbuild fails?
I have this script that runs when running Rails 7 with esbuild build, this is inside package.json in the scripts attribute, it's ran from the Rails procfile:
esbuild app/javascript/*.* --bundle --...
0
votes
1
answer
318
views
When I run migration, config.assets is not working in rails 7
I recently upgraded my application from rails 6.1 to rails 7.0.3 and I am facing some issues after that.
Following lines are defined in my development.rb file:
config.assets.debug = true
config.assets....
0
votes
1
answer
967
views
Error in Rails 7 dynamic loading of javascript file
I am updating a Rails template to v.7 and I'm running into a challenge with updating the dynamic calls to load various Javascript and stylesheets based on the controller/action.
<%= ...
6
votes
3
answers
3k
views
Rails 7 css assets are not working in production, need help understanding how the asset pipeline works without webpacker
Trying out rails 7, with tailwind and postcss.
I have a few stylesheets in assets/stylesheets, which I import through a file called imports.css in the same folder.
//imports.css
@import stylesheet1....