Change to a build architechture that just delegates to NPM. Much better than a custom script...