Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Support files with extension .react.js #13

Closed
pbomb opened this issue Oct 29, 2014 · 1 comment · Fixed by #14
Closed

Support files with extension .react.js #13

pbomb opened this issue Oct 29, 2014 · 1 comment · Fixed by #14

Comments

@pbomb
Copy link

pbomb commented Oct 29, 2014

React 0.12.0 was just released and no longer requires the /** @jsx React.DOM */ pragma at the top of the file. The React components in their example apps in the flux repo (https://github.com/facebook/flux/tree/master/examples/flux-chat/js/components) use .react.js file extensions instead of .jsx ones. However, if I remove the pragma, files with .react.js extension are no longer treated as JSX files since the code looks for one of .jsx or the pragma. Could you allow .react.js files by default to be treated as JSX files? Or, alternately, allow the user to configure the grunt task to specify the file suffix they're using?

@tillarnold
Copy link
Owner

A configurable suffix would be a good idea. I think that .react.js files should be treated as JSX files per default since flux uses this suffix. I'll add the .react.js suffix recognition and I'll add the configurable suffix option later on.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants