NodeJS nodegui module could not be found

Viewed 875

Attempting to get nodegui running on a blank nodeJS project, but it won't run. The example starter-project runs fine, however I do not want to use webpack on my project.

Error when running node main.js:

internal/modules/cjs/loader.js:1208
  return process.dlopen(module, path.toNamespacedPath(filename));
                 ^

Error: The specified module could not be found.
\\?\C:\Users\user\Documents\project\node_modules\@nodegui\nodegui\build\Release\nodegui_core.node
�[90m    at Object.Module._extensions..node (internal/modules/cjs/loader.js:1208:18)�[39m
�[90m    at Module.load (internal/modules/cjs/loader.js:1002:32)�[39m
�[90m    at Function.Module._load (internal/modules/cjs/loader.js:901:14)�[39m
�[90m    at Module.require (internal/modules/cjs/loader.js:1044:19)�[39m
�[90m    at require (internal/modules/cjs/helpers.js:77:18)�[39m
    at Object.<anonymous> (C:\Users\user\Documents\project\node_modules\�[4m@nodegui�[24m\nodegui\dist\lib\utils\addon.js:3:15)
�[90m    at Module._compile (internal/modules/cjs/loader.js:1158:30)�[39m
�[90m    at Object.Module._extensions..js (internal/modules/cjs/loader.js:1178:10)�[39m
�[90m    at Module.load (internal/modules/cjs/loader.js:1002:32)�[39m
�[90m    at Function.Module._load (internal/modules/cjs/loader.js:901:14)�[39m

main.js:

const { QMainWindow } = require("@nodegui/nodegui");

const win = new QMainWindow();
win.show();

global.win = win;

When running npm install @nodegui/nodegui this is the output.

Windows 10 x64 build 18363, NodeJS version 12.16.1, NPM version 6.14.2, NodeGUI version 0.16.0

1 Answers

It's seem specified module is missing in your project you need to run

npm i --save specified

Related