Open 3den opened 8 years ago
the tests we current have seems to be very integrated so I am not sure that is the proper way to test this feature
@3den for jsx support, did you add .jsx
to sprockets as an application/javascript
type file? Or how are you transforming the files? I don't have a use case for .jsx
as an extension myself but I'm curious how you're using them.
You'll also need to add .jsx
here -> https://github.com/Shopify/sprockets-commoner/blob/master/js/babel-plugin-sprockets-commoner-internal/index.js#L254. Currently the extension support is a bit all over the place
@bouk with https://github.com/reactjs/react-rails .jsx
files work fine i did not had to change anything on sprockets, also if I rename the react files to .js
it works fine but that is non-standard. I was able to get the client side rendering of components to work server-side is pretty buggy.
I started migrating to sprockets-commoner mostly because i wanted to use npm instead of bower, so far is being very challenging and the performance is pretty slow :(
@bouk can you help me to fix this test?
@3den I'd prefer an integration test like the other tests, it's the best way to make sure it'll actually work with all the other features
Any update on this?
As a workaround, you might be able to get away with using a .js
extension and just have all .js
files run through babel-preset-react
.
@bouk I need this to be able to load jsx files