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

webpack: packaged app has incorrect reference to renderer index.js #1034

Closed
3 tasks done
malept opened this issue Jul 17, 2019 · 4 comments · Fixed by #1035
Closed
3 tasks done

webpack: packaged app has incorrect reference to renderer index.js #1034

malept opened this issue Jul 17, 2019 · 4 comments · Fixed by #1035

Comments

@malept
Copy link
Member

malept commented Jul 17, 2019

Preflight Checklist

  • I have read the contribution documentation for this project.
  • I agree to follow the code of conduct that this project follows, as appropriate.
  • I have searched the issue tracker for an issue that matches the one I want to file, without success.

Issue Details

  • Electron Forge Version:
    • 6.0.0-beta.42
  • Operating System:
    • all
  • Last Known Working Electron Forge version::
    • 6.0.0-beta.39

Please describe your issue:

When a Forge project using the Webpack template is packaged, the renderer file should be referenced as ../main_window/index.js, not /main_window/index.js.

Please provide either a failing minimal testcase (with a link to the code) or detailed steps to
reproduce your problem. Using electron-forge init is a good starting point, if that is not the
source of your problem.

On Linux:

$ npx --no-install --ignore-existing create-electron-app --template=webpack webpack-test
✔ Initializing Project Directory
✔ Initializing Git Repository
✔ Copying Starter Files
✔ Initializing NPM Module
✔ Installing NPM Dependencies
✔ Locating custom template: "webpack"
✔ Installing Template Dependencies
✔ Setting up Forge configuration
✔ Setting up webpack configuration
$ cd my-new-app
$ npm run package
✔ Checking your system
✔ Compiling Main Process Code
✔ Compiling Renderer Template
✔ Preparing to Package Application for arch: x64
✔ Preparing native dependencies
✔ Packaging Application
$ out/my-new-app-linux-x64/my-new-app

screenshot of error in package

Please note: this bug is confirmed. Any comment that says anything to the effect of "I also have this problem" will be minimized.

@shimaore
Copy link
Contributor

My fix in #1021 was incorrect.

I'll do a new PR.

@malept
Copy link
Member Author

malept commented Jul 17, 2019

Much appreciated!

@shimaore
Copy link
Contributor

#1035 should be at the right place this time

malept pushed a commit that referenced this issue Jul 17, 2019
This reverts improper PR#1021 and re-implements the changes I have in the JS (compiled) code at the right place.

Fixes #1034.
@rafael-trevisan
Copy link

The path for the index.js seems to be correct in the 6.0.0-beta.43 but some css I am importing in the renderer.js are not being loaded now.

import $ from 'jquery';
import '@progress/kendo-ui';
import '@progress/kendo-theme-bootstrap';
import './index.css';

console.log('👋 This message is being logged by "renderer.js", included via webpack');

image

image

The packaged app is looking at the renderer/main_window/ for these 2 css files, but they are actually located in the renderer/ folder.

dsanders11 pushed a commit that referenced this issue Jan 14, 2023
Bumps [actions/setup-node](https://github.com/actions/setup-node) from 3.1.0 to 3.1.1.
- [Release notes](https://github.com/actions/setup-node/releases)
- [Commits](actions/setup-node@v3.1.0...v3.1.1)

---
updated-dependencies:
- dependency-name: actions/setup-node
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants