Reputation: 83
I'm looking to specifiy that i want that one of my depedencies needs to be compiled from source in package.json to npm. I searched in google but I didn't found any way to do this. Is it simply possible ?
Upvotes: 6
Views: 5386
Reputation: 2206
Steps like compiling would be executed during either a "prepublish" or "install" script hook: https://docs.npmjs.com/misc/scripts
And npm recommends using gyp to create build scripts necessary for packages: https://github.com/nodejs/node-gyp
Upvotes: 3