loading...

re: Getting started with Electron and Svelte VIEW POST

FULL DISCUSSION
 

I had one issue setting it up on Windows. Had to change 2 things...

Change the npm script:

"pure-electron-dev": "set NODE_ENV=development && electron ."

And trim() the incoming process.env.NODE_ENV

const mode = process.env.NODE_ENV.trim()

...

if (mode === 'development') {
  // set up watcher
}

Very well done article though, thank you!

 

Thanks @personthing !
Changed the post to use cross-env as more folks were running into this!

code of conduct - report abuse