Comments (10)
@rupurt As a workaround, just create an empty file right now.
If you could submit a PR for your enhancement, we'd take it!
from react_on_rails.
@justin808 that's what I did 😄
I'll see if I have some time to take a stab at it over the weekend.
from react_on_rails.
@rupurt That would be awesome! Definitely take a look at the lib/generators/react_on_rails/base_generator.rb
file, as I believe this may be the right place for this logic. We could also try putting this logic inside of the config/initializers/react_on_rails.rb
initializer, although I'm not sure if that work and/or maybe that's not a solution for your specific scenario.
from react_on_rails.
Generator raises error when application.css.scss
is not found as well (in our case we use application.scss), I think it's a similar issue. It might be good to be able to config these files in initializer.
from react_on_rails.
@yorzi I would say this issue is an enhancement, whereas yours is closer to a bug. I have therefore made a separate issue: #86
from react_on_rails.
@robwise 👍 I can look into that today.
from react_on_rails.
@yorzi Would be awesome if you can submit a PR to fix the missing files!
from react_on_rails.
@robwise Can we close this one?
from react_on_rails.
@justin808 negative, I fixed a different issue that was with the application.scss, not js. This issue will still occur. I can come up with a fix if you want.
- We can allow passing an argument to specify a different file than application.js
- We can simply create an application.js file if it is missing
The latter solution would not actually really fix @rupurt's problem, though, but it would at least let the generator run through completion by default instead of essentially forcing him to figure out that he needs to make his own application.js file, run the generator, and then move the code manually to where he wants it.
from react_on_rails.
@robwise I vote for 2) with a warning as the user will see the diff and can take appropriate action.
from react_on_rails.
Related Issues (20)
- Setting webpack target to node HOT 1
- Turbo forms with react_component not rendering React HOT 4
- `react_component` and `react_component_hash` raises pack not found warning even when corresponding chunks are present in `manifest`
- Refactor `lib/react_on_rails/helper.rb` HOT 1
- ./bin/dev is not executable in default HOT 1
- How to create Procfile.dev? HOT 2
- bin/dev: Please ensure `Procfile.dev` exist in your project! HOT 3
- How do I stop react_on_rails from generating packs? HOT 12
- How to disable sourcemap? HOT 1
- Update documentation based on Shakapacker 7 HOT 1
- Outdated link in the documentation redirects to Non-Found Page HOT 1
- Client rendering crashes when configuring `optimization.runtimeChunk` to `multiple` HOT 3
- Include Ruby 3 and node 18 to CI workflows HOT 2
- Pack generation runs with nil components_subdirectory HOT 3
- Concurrency performance HOT 3
- When server-bundle.js register a lot of server render components making the server render performance reduce big HOT 2
- Remove `request_digest` from `render_options` for version 14 HOT 1
- Convert spec/dummy/client to Typescript
- Change primary branch name from `master` to `main` HOT 2
- Add support for Vite
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from react_on_rails.