
tkhobbes
Modern Front-End Development for Rails - application does not start after run bin/setup (page xviii)
After some hassle, I was able to finally run bin/setup, now I have started the rails server but I get this error message right when I visit the homepage:
ctionView::Template::Error (Webpacker can’t find application.css in /Users/thomas/Documents/Websites/rails-frontend/public/packs/manifest.json. Possible causes:
- You want to set webpacker.yml value of compile to true for your environment
unless you are using thewebpack -w
or the webpack-dev-server. - webpack has not yet re-run to reflect updates.
- You have misconfigured Webpacker’s config/webpacker.yml file.
- Your webpack configuration is not creating a manifest.
Your manifest contains:
{
“application.js”: “/packs/js/application-e2d1692aebb36c02d64a.js”,
“entrypoints”: {
“application”: {
“assets”: {
“js”: [
“/packs/js/runtime-a264c6705547ad01acbb.js”,
“/packs/js/vendors-node_modules_rails_activestorage_app_assets_javascripts_activestorage_js-node_modules-2576d4-9a719947c3eb6bc6295c.js”,
“/packs/js/application-e2d1692aebb36c02d64a.js”
]
}
}
},
“js/application-e2d1692aebb36c02d64a.js.map”: “/packs/js/application-e2d1692aebb36c02d64a.js.map”,
“js/runtime-a264c6705547ad01acbb.js.map”: “/packs/js/runtime-a264c6705547ad01acbb.js.map”,
“js/vendors-node_modules_rails_activestorage_app_assets_javascripts_activestorage_js-node_modules-2576d4-9a719947c3eb6bc6295c.js”: “/packs/js/vendors-node_modules_rails_activestorage_app_assets_javascripts_activestorage_js-node_modules-2576d4-9a719947c3eb6bc6295c.js”,
“js/vendors-node_modules_rails_activestorage_app_assets_javascripts_activestorage_js-node_modules-2576d4-9a719947c3eb6bc6295c.js.map”: “/packs/js/vendors-node_modules_rails_activestorage_app_assets_javascripts_activestorage_js-node_modules-2576d4-9a719947c3eb6bc6295c.js.map”,
“runtime.js”: “/packs/js/runtime-a264c6705547ad01acbb.js”
}
):
5:
6: <%= csrf_meta_tags %>
7: <%= csp_meta_tag %>
8: <%= stylesheet_pack_tag(
9: “application”,
10: media: “all”,
11: “data-turbolinks-track”: “reload”
app/views/layouts/application.html.erb:8
I am not 100% sure what is wrong here?
First Post!

noelrappin
So, webpacker is not generating the application.css
file for some reason – this is a webpack error that sometimes happens intermittently when webpacker gets into a strange state.
Are you running this off the sample code directly, or have you been trying to build the app yourself? Is there another error in the logs that suggests that the app/packs/entrypoint/application.scss file didn’t compile?
You could try removing the /public/packs directory and trying again?
I’m sorry you are having this problem.
Alternately, the second edition of the book doesn’t use webpack, and should be easier to set up, if you purchased the ebook from Pragmatic, you get the second edition for free, and it might be worth you trying out.
Noel
Popular Prag Prog topics










Other popular topics










Latest in PragProg
Latest (all)
Categories:
Popular Portals
- /elixir
- /rust
- /wasm
- /ruby
- /erlang
- /phoenix
- /keyboards
- /js
- /rails
- /python
- /security
- /go
- /swift
- /vim
- /clojure
- /java
- /haskell
- /emacs
- /svelte
- /onivim
- /typescript
- /crystal
- /c-plus-plus
- /tailwind
- /kotlin
- /gleam
- /react
- /flutter
- /elm
- /ocaml
- /vscode
- /opensuse
- /ash
- /centos
- /php
- /deepseek
- /zig
- /scala
- /html
- /debian
- /nixos
- /lisp
- /agda
- /react-native
- /textmate
- /sublime-text
- /kubuntu
- /arch-linux
- /ubuntu
- /revery
- /manjaro
- /spring
- /django
- /diversity
- /lua
- /nodejs
- /julia
- /c
- /slackware
- /neovim