Version 0.8.0 is broken on Windows: SyntaxError: Unexpected token < #33
Comments
Ok, so the problem is going to be how we register the transform. The big change in 0.8 was to switch to babel, which meant that we changed how we detected what needed to be transformed. Specifically we now build up a regex and pass that into babel. AFAIK this was only tested on *nix so presumably we need to either build a better regex or there's bug in babel (I'm assuming it's our problem though). I don't have a Windows machine super handy but this will hopefully be a pretty small fix. Would you or @gocreating be willing to help out and do a little bit of detective work to make the regex match what's being required? (might need to do |
@zpao excuse me, I am not familiar with regex and react, and I think I cannot help you in the meantime. |
I use node-jsx and the error did not happen. I run |
I got the same problem , To fix it ,I readed the Babel's docs and finded that the 'only' requires an array of glob paths, so I modified the index.js
It fixed. |
@xuteng - Hmm, http://babeljs.io/docs/usage/require/ indicates it takes a regex. And actually looking at the src (https://github.com/babel/babel/blob/master/src/babel/api/register/node.js#L154) it looks like both will work and it'll convert to an array and regex from that. So I think all that you're really doing is creating a regex without the leading Can you log what |
The |
Problem
Version 0.8.0 is broken on Windows.
See Error below.
Steps To Reproduce
Error
Issue Duplicate?
#32
Node Package Versions
"express-react-views": "0.8.0",
"react": "0.13.3"
OS Version
Windows 7 Pro SP1 (64-bit)
The text was updated successfully, but these errors were encountered: