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

Using --target node and --target electron #4

Open
nyxynyx opened this issue Apr 29, 2020 · 0 comments
Open

Using --target node and --target electron #4

nyxynyx opened this issue Apr 29, 2020 · 0 comments

Comments

@nyxynyx
Copy link

nyxynyx commented Apr 29, 2020

Hello there, your boilerplate is working great until I encountered the errors fs.existsSync is not a function and Cannot statically evaluate fs argument after trying to use another npm package. While trying to troubleshoot it, I tried to specify the Parcel targets node and electron by changing the line in package.json from

"react-start": "parcel -p 3000 index.html --out-dir build",

to

"react-start": "parcel -p 3000 index.html --out-dir build --target node",

and

"react-start": "parcel -p 3000 index.html --out-dir build --target electron",

However, running yarn start no longer launch the Electron app and no server is listening to http://localhost:3000.

What is the correct way to set the targets to node and electron?

Thank you very much!


GitHub Repo to reproduce problem:
https://github.com/nyxynyx/electron-react-parcel-boilerplate-problem

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

No branches or pull requests

1 participant