npm rebuild, electron-rebuild doesn't use special parameters

157 Views Asked by At

I have an electron/React app running. So after I install all packages I have to execute electron-rebuild so there are no version issues.

I install one package in the preinstall script: npm install better-sqlite3 --build-from-source --sqlite3=my sqlite amalgamation folder

Now the problem is that electron-rebuild/npm rebuild just installs better-sqlite3 and not better-sqlite3 with my customized amalgamation.

This makes it unusable for me because I need my customized version of sqlite.

Does anyone know how to solve this, how to make electron-rebuild/npm rebuild install that package with the extra parameters?

1

There are 1 best solutions below

0
On

I created a library to fix this issue/get around it: https://www.npmjs.com/package/better-sqlite3-sqleet.

So the problem is solved for me, but it would be nice to still have an answer on the original question.