TypeError: fs.readdirSync is not a function
jhorgint opened this issue · 5 comments
I'm using Create-React-App, how to overcome this
is there a solution?
Can you provide full error reporoduction steps? Otherwise I'm afraid I can't help.
i'm using "node v6.11.3" "npm 3.10.10" "create-react-app 1.4.0"
seems it's not an error on fs-jetpack when I tried to use fs [import fs from 'fs'] I obtained the same error in my code, I think is a config problem on create-react-app, I had published the issue then I noticed that
I just used this line of code: console.log(jetpack.list())
any help is Welcome
I have read "The browser doesn't allow access to the file system" at stackoverflow.com
this is why I can't use 'fs' on my project?
I don't know what you want to do (don't know the context), so can't tell you something meaningful. "FS" module is exclusive to node.js, so indeed you can't use it in the browser.
If you'll become sure that there is some bug in fs-jetpack, please open another issue with precise steps to reproduce the problem :)
Cheers!
I feel sorry :(
Thanks for your time.