Coder Social home page Coder Social logo

Comments (17)

lacymorrow avatar lacymorrow commented on April 28, 2024 3

This issue is back, macos 10.14

Cant even page the example app.

from electron-react-boilerplate.

0x80 avatar 0x80 commented on April 28, 2024

I've triggered openDevTools() on the release build and it appears the bundle file is not being found:

failed to load file:///Users/me/tmp/electron-react-boilerplate/release/darwin/ElectronReact.app/Contents/Resources/app/dist/bundle.js

There is indeed no bundle file in the dist folder.

from electron-react-boilerplate.

chentsulin avatar chentsulin commented on April 28, 2024

Now It does not execute bundle in package process.

Maybe I should include exec webpack in package.js

from electron-react-boilerplate.

chentsulin avatar chentsulin commented on April 28, 2024

And I will include electron-debug when it be published to npm.

from electron-react-boilerplate.

chentsulin avatar chentsulin commented on April 28, 2024

I even find out some weird behavior about electron-packager with ignore option.....some time whole app will not be included by electron-packager

Update:
electron-packager's filter match to a whole path name..

/Users/chentsulin/Projects/test/electron-react-boilerplate

will match '/test($|/)' in ignore:

ignore: [
    '/test($|/)',
    '/tools($|/)',
    '/release($|/)'
].concat(devDeps.map(function(name) { return '/node_modules/' + name + '($|/)' }))

be careful with test, tools, release before this issue be fixed.

from electron-react-boilerplate.

akovalyov avatar akovalyov commented on April 28, 2024

@0x80 have you run npm run build before npm run package ? I have run in the same issue.
@chentsulin maybe the build task should be combined with package one?

from electron-react-boilerplate.

0x80 avatar 0x80 commented on April 28, 2024

@akovalyov Thanks that looks like the problem.

package.json build step should reference webpack.config.production.js instead of webpack-production.config.js

--edit--
the del command was ok after all ...

I'm too tired for a PR right now ;)

from electron-react-boilerplate.

0x80 avatar 0x80 commented on April 28, 2024

Also I also noticed that the css file is not being picked up somehow

from electron-react-boilerplate.

0x80 avatar 0x80 commented on April 28, 2024

It seems to me that the whole package app content is off at the moment. It includes the app folder with all the react sources and the webpack configs and all those things.

I think you want to end up eventually with something like this:

.
├── app.html
├── bundle.js
├── main.css
├── node_modules
└── stats.json

But I haven't figure out how to get there yet. Just planting some seeds :)

Also the reason the css is not picked up is probably because it is extracted into a seperate css file where in the dev version it is kept in the bundle. If it's a seperate file in production it should be referenced in the app.html file I guess.

from electron-react-boilerplate.

chentsulin avatar chentsulin commented on April 28, 2024

This should already be fixed.

from electron-react-boilerplate.

elmehalawi avatar elmehalawi commented on April 28, 2024

I'm having the same problem (and I did do npm run build). How do I get the dev tools in the packaged app so I can figure out whats going on? I tried passing NODE_ENV=development, but that didn't seem to work.

from electron-react-boilerplate.

amilajack avatar amilajack commented on April 28, 2024

The packaged app should not contain the dev tools. Run:

npm run dev

from electron-react-boilerplate.

elmehalawi avatar elmehalawi commented on April 28, 2024

That gives me my app, which works correctly. But when I package it, I just get the blank page, and no dev tools to find out why.

from electron-react-boilerplate.

amilajack avatar amilajack commented on April 28, 2024

When did you fork or clone this repo?

from electron-react-boilerplate.

elmehalawi avatar elmehalawi commented on April 28, 2024

Not sure when, but I have version 0.10.0.

from electron-react-boilerplate.

amilajack avatar amilajack commented on April 28, 2024

The repo version is not updated frequently (last updated April 17). You should making a fresh clone of the repo:

If you forked the repo:

git remote add upstream https://github.com/chentsulin/electron-react-boilerplate.git
git pull upstream master

If you didn't change the origin:

git pull --all

from electron-react-boilerplate.

c446984928 avatar c446984928 commented on April 28, 2024

try this :

function createWindow () {
  mainWindow = new BrowserWindow({
    //...
  })
// use this to open dev tools manualy to debug
 mainWindow.webContents.openDevTools()
//...
}

from electron-react-boilerplate.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.