pbarbiero / enhanced-electron-react-boilerplate Goto Github PK
View Code? Open in Web Editor NEWModern and somewhat opinionated react+electron+webpack boilerplate
License: MIT License
Modern and somewhat opinionated react+electron+webpack boilerplate
License: MIT License
what is the point of hot reload if ones state is being killed on every change?
...or have I messed something up?
Thank for great boilerpalte!!
At some point I was not able to create package and I'm getting the next error:
Asset Size Chunks Chunk Names
font/photon-entypo__10lnA.eot 48.6 kB [emitted]
font/photon-entypo__i1XI6.woff 30.7 kB [emitted]
font/photon-entypo__BJxdK.ttf 48.5 kB [emitted]
bundle.js 2.51 MB 0 [emitted] [big] main
bundle.css 40.9 kB 0 [emitted] main
index.html 227 bytes [emitted]
ERROR in unknown: Invalid number (70027:15)
When checking the bundle.js at this line the code there is:
function mkdirP (p, opts, f, made) {
...
if (mode === undefined) {
mode = 0777 & (~process.umask()); // the issue is with the octal 0777 that should be 0o777
}
....
}
Any idea how to fix it?
Hi,
Thank you for providing such a boilerplate. I have been using this boiler plate to build my electron application. I added an image folder inside src/assets and imported images from the same inside react component. The images I import is loaded during development mode but not inside production mode.
I searched on the Internet and some one has written to add url-loaders instead of file-loader in webpack build configuration. I did the same and it worked is this a correct solution or else what are my options
looking at this starter kit i don't see an index.html file. How do i change the title and icon of the app? where is the index.html file?
In the file: webpack.dev.config.js
Compiled bootstrap from the node module 'bootstrap' didn't work until I made this change.
The CSS loader change from
{ test: /\.css$/, use: [{ loader: 'style-loader' }, { loader: 'css-loader' }], include: defaultInclude },
to
{ test: /\.css$/, loader:[ 'style-loader', 'css-loader' ] },
Hello,
Thanks for you work.
I tried today to test your projet, I got this warning
npm WARN deprecated [email protected]: babili has been renamed to babel-minify. Please update to babel-preset-minify
I have done a npm ls to find out which dependancies use it :
`-- [email protected]
`-- [email protected]
PS: If you want to check out another dev dependancies , I use https://david-dm.org/pbarbiero/enhanced-electron-react-boilerplate?type=dev
Hi,
Is there a reason why you separate the dev commands into two commands to be run in separate consoles?
Another approach would be to spawn a separate electron process in webpack.dev.config.js
. Borrowing heavily from electron-react-boilerplate
, I was able to do the following:
In webpack.dev.config.js
, I required child_process.spawn
:
const { spawn } = require('child_process');
In the devServer
section, I added:
setup() {
spawn(
'npm',
['run', 'testDev'],
{ shell: true, env: process.env, stdio: 'inherit' }
)
.on('close', code => process.exit(0))
.on('error', spawnError => console.error(spawnError));
}
See:
https://github.com/chentsulin/electron-react-boilerplate/blob/master/webpack.config.renderer.dev.js
Is there a disadvantage to doing this? If it does make sense to do this, can I submit a pull request?
This project (and the basic-
) version are great BTW. A much needed update to something like electron-react-boilerplate
. THANKS!
Hi again. The config file definitely gets updated on save, but the config object is empty upon reload. It looks like the app.on('ready') function that initializes it in electron-json-config is never getting called. Any idea why?
I suppose this could be a bug in electron-json-config??
Hi, trying to use your cool boilerplate. Works great in dev, but having probs with packaged app. Using Node 8.8.0/NPM 5.4.2 (OS X) and a clean clone of your repo, the built app just displays an empty window :(
Can't build at all with earlier versions (npm prune --production fails).
Pls advise...
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.