# Trouble Installing Underscore with NPM

**URL:** <https://forum.codewithmosh.com/t/trouble-installing-underscore-with-npm/482>\
**Category:** Node\
**Created:** [November 3, 2020, 6:34pm UTC](https://forum.codewithmosh.com/t/trouble-installing-underscore-with-npm/482 "2020-11-03T18:34:25Z")\
**Posts on this page:** 15\
**Page:** 1

<div class="post-metadata">

**Author:** ![chiahao](https://avatars.discourse-cdn.com/v4/letter/c/df788c/32.png) [@chiahao](https://forum.codewithmosh.com/u/chiahao)\
**Post date:** [November 3, 2020, 6:34pm UTC](https://forum.codewithmosh.com/t/trouble-installing-underscore-with-npm/482/1 "2020-11-03T18:34:25Z")

</div>

Hi,

I am trying to install underscore but my npm version 5.5.1 does not support Node LTS v14.15.0

I have tried to uninstall/reinstall NodeJS. I also tried to update npm with npm install -g npm. Nothing seems to work. Can anyone help with this? I am new to NodeJS. Thank you.

 ![2020-11-02 (3)](https://us1.discourse-cdn.com/flex020/uploads/codewithmosh/original/1X/2546e0dcfb2a6e83671a6af8800b2e862ee41c89.png)

---

<div class="post-metadata">

**Author:** ![Adina](https://avatars.discourse-cdn.com/v4/letter/a/47e85d/32.png) [@Adina](https://forum.codewithmosh.com/u/Adina)\
**Post date:** [November 3, 2020, 7:08pm UTC](https://forum.codewithmosh.com/t/trouble-installing-underscore-with-npm/482/2 "2020-11-03T19:08:59Z")

</div>

Hi,  
I actually struggled with this yesterday.  
(and I think the error occurred because you downgraded your version of NPM to 5.5.1 to match Mosh’s…)  
Here’s what worked for me.  
You do want to update NPM, and in order to do so you would have to delete the folders ‘npm’ and ‘npm-cache’ at location “~AppData/Roaming” (press windows+r and then type ‘%AppData%’ to get there)  
then run: npm i -g npm@latest  
hope this works

---

<div class="post-metadata">

**Author:** ![chiahao](https://avatars.discourse-cdn.com/v4/letter/c/df788c/32.png) [@chiahao](https://forum.codewithmosh.com/u/chiahao)\
**Post date:** [November 3, 2020, 7:36pm UTC](https://forum.codewithmosh.com/t/trouble-installing-underscore-with-npm/482/3 "2020-11-03T19:36:23Z")

</div>

Hi Adina,

It worked! You are a lifesaver. Thank you!

---

<div class="post-metadata">

**Author:** ![Adina](https://avatars.discourse-cdn.com/v4/letter/a/47e85d/32.png) [@Adina](https://forum.codewithmosh.com/u/Adina)\
**Post date:** [November 3, 2020, 8:47pm UTC](https://forum.codewithmosh.com/t/trouble-installing-underscore-with-npm/482/4 "2020-11-03T20:47:51Z")

</div>

Yay!!  
So glad to be able to help with my little experience… 😀

---

<div class="post-metadata">

**Author:** ![xavicwm](https://avatars.discourse-cdn.com/v4/letter/x/e47c2d/32.png) [@xavicwm](https://forum.codewithmosh.com/u/xavicwm)\
**Post date:** [January 22, 2021, 2:21pm UTC](https://forum.codewithmosh.com/t/trouble-installing-underscore-with-npm/482/5 "2021-01-22T14:21:10Z")

</div>

That was a tough one to find out, thanks a lot Adina, it did work although using a newer version than Mosh is using, hope I can keep up with the course compatibility.  
Mosh is good but cannot do all the troubleshooting that comes up I understand.

---

<div class="post-metadata">

**Author:** ![Adina](https://avatars.discourse-cdn.com/v4/letter/a/47e85d/32.png) [@Adina](https://forum.codewithmosh.com/u/Adina)\
**Post date:** [January 24, 2021, 5:00pm UTC](https://forum.codewithmosh.com/t/trouble-installing-underscore-with-npm/482/6 "2021-01-24T17:00:48Z")

</div>

Lots of luck, xavicwm!!!

---

<div class="post-metadata">

**Author:** ![jayrix](https://avatars.discourse-cdn.com/v4/letter/j/96bed5/32.png) [@jayrix](https://forum.codewithmosh.com/u/jayrix)\
**Post date:** [February 13, 2021, 10:56am UTC](https://forum.codewithmosh.com/t/trouble-installing-underscore-with-npm/482/7 "2021-02-13T10:56:52Z")

</div>

I have similar issue but i have mac. So above does not work?

I have tried similar approach to update npm with below commands but no luck:

sudo npm install -g npm@latest  
and  
sudo npm install -g npm@next  
and  
sudo npm install -g npm@6.14.11

Error:  
WARNING: You are likely using a version of node-tar or npm that is incompatible with this version of Node.js.  
Please use either the version of npm that is bundled with Node.js, or a version of npm (\> 5.5.1 or \< 5.4.0) or node-tar (\> 4.0.1) that is compatible with Node.js 9 and above.  
npm[30283]: …/src/node\_zlib.cc:576:static void node::(anonymous namespace)::ZlibStream::Init(const FunctionCallbackInfov8::Value &): Assertion `args.Length() == 7 && “init(windowBits, level, memLevel, strategy, writeResult, writeCallback,” " dictionary)"’ failed.  
1: 0x1012e4da5 node::Abort() (.cold.1) [/usr/local/bin/node]  
2: 0x1000a6239 node::Abort() [/usr/local/bin/node]  
3: 0x1000a60a1 node::Assert(node::AssertionInfo const&) [/usr/local/bin/node]  
4: 0x10014c9c2 node::(anonymous namespace)::ZlibStream::Init(v8::FunctionCallbackInfov8::Value const&) [/usr/local/bin/node]

---

<div class="post-metadata">

**Author:** ![jayrix](https://avatars.discourse-cdn.com/v4/letter/j/96bed5/32.png) [@jayrix](https://forum.codewithmosh.com/u/jayrix)\
**Post date:** [February 14, 2021, 2:25am UTC](https://forum.codewithmosh.com/t/trouble-installing-underscore-with-npm/482/8 "2021-02-14T02:25:32Z")

</div>

Fixed my own issue with reinstalling node.

---

<div class="post-metadata">

**Author:** ![\_lyndasowunmi](https://avatars.discourse-cdn.com/v4/letter/_/a9adbd/32.png) [@\_lyndasowunmi](https://forum.codewithmosh.com/u/_lyndasowunmi)\
**Post date:** [March 1, 2021, 5:25pm UTC](https://forum.codewithmosh.com/t/trouble-installing-underscore-with-npm/482/9 "2021-03-01T17:25:13Z")

</div>

Hi Adina, thanks for the tips. So, after npm i -g npm@latest, what’s the next thing to do on the terminal? Still continue with the npm i -g parcel-bundler? I tried your steps but it didn’t work.

---

<div class="post-metadata">

**Author:** ![\_lyndasowunmi](https://avatars.discourse-cdn.com/v4/letter/_/a9adbd/32.png) [@\_lyndasowunmi](https://forum.codewithmosh.com/u/_lyndasowunmi)\
**Post date:** [March 1, 2021, 5:26pm UTC](https://forum.codewithmosh.com/t/trouble-installing-underscore-with-npm/482/10 "2021-03-01T17:26:45Z")

</div>

Hi Jayrix, when you reinstalled node to solve this problem, which version did you re-install? Did you use the LTS or the newest version?

---

<div class="post-metadata">

**Author:** ![lesliefreeman](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.codewithmosh.com/lesliefreeman/32/1081_2.png) [@lesliefreeman](https://forum.codewithmosh.com/u/lesliefreeman)\
**Post date:** [March 6, 2021, 8:37pm UTC](https://forum.codewithmosh.com/t/trouble-installing-underscore-with-npm/482/11 "2021-03-06T20:37:27Z")

</div>

Useful topic, thanks! 🤝

---

<div class="post-metadata">

**Author:** ![sharel](https://avatars.discourse-cdn.com/v4/letter/s/8dc957/32.png) [@sharel](https://forum.codewithmosh.com/u/sharel)\
**Post date:** [August 10, 2021, 4:25pm UTC](https://forum.codewithmosh.com/t/trouble-installing-underscore-with-npm/482/12 "2021-08-10T16:25:04Z")

</div>

Thank you, did it too, and it’s work for me!!!

---

<div class="post-metadata">

**Author:** ![Africanprince](https://avatars.discourse-cdn.com/v4/letter/a/cc9497/32.png) [@Africanprince](https://forum.codewithmosh.com/u/Africanprince)\
**Post date:** [December 1, 2021, 2:41pm UTC](https://forum.codewithmosh.com/t/trouble-installing-underscore-with-npm/482/13 "2021-12-01T14:41:38Z")

</div>

I re-installed on the Mac and that worked for me. Thanks…

---

<div class="post-metadata">

**Author:** ![Pradeep](https://avatars.discourse-cdn.com/v4/letter/p/f0a364/32.png) [@Pradeep](https://forum.codewithmosh.com/u/Pradeep)\
**Post date:** [April 21, 2022, 6:59am UTC](https://forum.codewithmosh.com/t/trouble-installing-underscore-with-npm/482/14 "2022-04-21T06:59:56Z")

</div>

Thanks a lot, Adina . this worked perfectly

---

<div class="post-metadata">

**Author:** ![dkitchens](https://avatars.discourse-cdn.com/v4/letter/d/8797f3/32.png) [@dkitchens](https://forum.codewithmosh.com/u/dkitchens)\
**Post date:** [April 9, 2024, 11:16pm UTC](https://forum.codewithmosh.com/t/trouble-installing-underscore-with-npm/482/15 "2024-04-09T23:16:57Z")

</div>

Thank you! I have looked around for two days and many hours to find this solution.
