{"id":3042,"date":"2023-12-05T15:34:50","date_gmt":"2023-12-05T14:34:50","guid":{"rendered":"https:\/\/nguenkam.com\/blog\/?p=3042"},"modified":"2023-12-12T12:22:15","modified_gmt":"2023-12-12T11:22:15","slug":"how-to-upgrade-a-globally-installed-package","status":"publish","type":"post","link":"https:\/\/nguenkam.com\/blog\/index.php\/2023\/12\/05\/how-to-upgrade-a-globally-installed-package\/","title":{"rendered":"how to upgrade a globally installed package"},"content":{"rendered":"\n<p>To update a globally installed Angular package, we can use the<em> npm command line tool<\/em>. <\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>\/\/ let's update the angular CLI which previously was installed globally \nnpm update -g @angular\/cli <\/code><\/pre>\n\n\n\n<p><strong><em>PS:<\/em><\/strong>  Note that we may need administrative privileges (permissions) to update global packages.<\/p>\n\n\n\n<h4>Variante II<\/h4>\n\n\n\n<p>We can also use the following command format on our command line: ( For example, let assume we want to update Angular CLI to version 17.0.0)<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>npm install -g @angular\/cli@17.0.0\n<\/code><\/pre>\n\n\n\n<p>After updating, we can check whether the package was updated successfully by running the following command:<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>ng v<\/code><\/pre>\n\n\n\n<p>This displays the installed Angular CLI version. If the update was successful, we should see the new version.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>To update a globally installed Angular package, we can use the npm command line tool. PS: Note that we may need administrative privileges (permissions) to update global packages. Variante II We can also use the following command format on our command line: ( For example, let assume we want to update Angular CLI to version [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":2048,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":[],"categories":[37,453],"tags":[776,196,273,197,308],"_links":{"self":[{"href":"https:\/\/nguenkam.com\/blog\/index.php\/wp-json\/wp\/v2\/posts\/3042"}],"collection":[{"href":"https:\/\/nguenkam.com\/blog\/index.php\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/nguenkam.com\/blog\/index.php\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/nguenkam.com\/blog\/index.php\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/nguenkam.com\/blog\/index.php\/wp-json\/wp\/v2\/comments?post=3042"}],"version-history":[{"count":3,"href":"https:\/\/nguenkam.com\/blog\/index.php\/wp-json\/wp\/v2\/posts\/3042\/revisions"}],"predecessor-version":[{"id":3049,"href":"https:\/\/nguenkam.com\/blog\/index.php\/wp-json\/wp\/v2\/posts\/3042\/revisions\/3049"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/nguenkam.com\/blog\/index.php\/wp-json\/wp\/v2\/media\/2048"}],"wp:attachment":[{"href":"https:\/\/nguenkam.com\/blog\/index.php\/wp-json\/wp\/v2\/media?parent=3042"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/nguenkam.com\/blog\/index.php\/wp-json\/wp\/v2\/categories?post=3042"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/nguenkam.com\/blog\/index.php\/wp-json\/wp\/v2\/tags?post=3042"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}