[Node] Prepare a package to be published to npm

In package.json file:

    "prepare": "npm run build",
    "postpublish": "git push --tags",

 

"prepare": make sure we don't forget to run build before publish the package

"postpublish": make sure after we publish the package, we also send tags to git

 

When we want to udpate the package version, we need to use "npm version [options]"

上一篇:[强网杯 随便注]总结


下一篇:PDO预处理prepare