Closed rensiu closed 4 years ago
@rensiu don't you have problem like this:
Module not found: Can't resolve 'font-manager'
i have installed font-manager
and rebuild it(with some warning).
my node version is 8.9.0.
@robberfree your environment for example: browser?electron?webpack? and your configuration
@rensiu
i am creating a app use React
and Electron
.just use Create React App
to manage the dependencies and other settings.
@robberfree if you run 'npm start' and your other node packages can't be resolved, you can add require('module').globalPaths.push(yourNodeModulesDir)
into your index.html.
try this and tell me result.
@rensiu very sorry for replay lately. Today I solved the problem with my colleague。
font-manager
to devDependencies
wrongly in old days.Now I install it to dependencies
electron-rebuild
to rebuild font-manager
after read this document:using-native-node-modulesthen I can require font-manager
and use it in main process.
Mac: When spellchecker and font-manager appear in the same process, electron crash!!! Windows system is ok.