npm uninstall

删除一个包

概要

npm uninstall [<@scope>/]<pkg>...

aliases: unlink, remove, rm, r, un

描述

这将卸载一个包,完全删除代表它安装的所有 npm。

它还会从 package.json 中的 dependenciesdevDependenciesoptionalDependenciespeerDependencies 对象中删除包。

此外,如果您有 npm-shrinkwrap.jsonpackage-lock.json,npm 也会更新这些文件。

--no-save 会告诉 npm 不要从你的 package.jsonnpm-shrinkwrap.jsonpackage-lock.json 文件中删除包。

ugfejdwpY+ptNiPE8H32M4r8Y/6P668oqr9wpC7N7fdDysN/r3viCG8LwAuf9zBYHiQr0xwqwJVB7QFkyMZFMsdQtzTLNtEyrQmNSVnNxzu2KpZbLigoqwvwUSB15fiqJnekJD0I3nJjWCPCaoXEIeXB7krXblwXCuG9KOkC7EiOuRMaYuEra00lvOeBZ+/WGbPUgRxC+j0PvcEZ7szG121CFAXgx0tnUcrzILxwOlB92hNUrcj+tkDs/1XiXv/NOwqa3bs0bYuzFgSojaM3VzMUPgXVAXJxmUPPo7IEGZdw2qBr565ZnBSMBtB7fsLrZPmT+T311MoMjUq5g2smQnh6OcpORF7ViRN+Nn2tvxTGbOgGfH8kKF4uaC7jzQHKekCd79Cl+hXC9okF/cjkIe/7cezyN2OQdbB3EDS5t8Q=

WmxS43IQV+5PGMo57IVUCG24J3Mry569rFthm9w1MR1uwPANv1wUFkRqwN9btgH1mnmbj6D3p0wHFGRCdyKKx78BzJgse5XLFV9kEHodeG8YdDDk7ix6GqP/W57PoSRMGsPzTYVLswqbKO9eudE+QtrhJaZH0iGZln7iofBe6X8eUeSdG9ZhrOnNeqq6BEE8L6enzL6ccoTwhwRw+DJQo6SEu9CrQt+XLv9b4083v/jE/ZDBH8PT2whPhwhAx1ofwpWriyDkaYAi42ea1SuU6g==

cFhDuMY6INguntVVwCoutylz/k4GZo2ginVjmIJfkbwYxCc6AvIDZzRO7zmQ0Rg7bgASeySDZzR9d0tmBzUeN3oaDuPlDuWMKAwem6cEEPsV3jW/GkZGWXWZ2Sq/l8dGTG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