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

core.require is not a function #5

Closed
mzmousa opened this issue May 13, 2016 · 4 comments
Closed

core.require is not a function #5

mzmousa opened this issue May 13, 2016 · 4 comments

Comments

@mzmousa
Copy link

mzmousa commented May 13, 2016

I added the line if (require ('electron-squirrel-startup')) return;
to the top of my electron app. I have all the required dependencies installed. However, I keep getting the error

TypeError: core.require is not a function

I am running electron v0.37.8 on a Windows 7 machine, node v.6.1.0 and npm v.3.8.9.

@plrthink
Copy link

not sure why this would happen? Everythings works fine for me on windows 10 with electron 0.36.6. I find this (https://discuss.atom.io/t/first-launch-of-electron/17511/2), hope it would be helpful.

@mzmousa
Copy link
Author

mzmousa commented May 16, 2016

Still nothing 😢 I removed the node_modules directory within electron-squirrel-startup and then did another npm install to no success. It's not so urgent for me anymore as I've figured out how to handle squirrel events myself, but it would still be nice if I knew the reason for this happening.

@imlucas
Copy link
Contributor

imlucas commented May 19, 2016

note the errant space after require

if (require ('electron-squirrel-startup')) return;

@imlucas imlucas closed this as completed May 19, 2016
@mzmousa
Copy link
Author

mzmousa commented May 19, 2016

I have literally never come across that before. Fuck, that makes me so mad, literally a space has driven me bat-shit crazy.
Anyways, it works now, thank you so much 😄

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

3 participants