Welcome to the Treehouse Community

Want to collaborate on code errors? Have bugs you need feedback on? Looking for an extra set of eyes on your latest project? Get support with fellow developers, designers, and programmers of all backgrounds and skill levels here with the Treehouse Community! While you're at it, check out some resources Treehouse students have shared here.

Looking to learn something new?

Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and join thousands of Treehouse students and alumni in the community today.

Start your free trial

JavaScript Building a MEAN Application Introduction to the MEAN Stack Setting Up an Express Application

Anthony Davis
Anthony Davis
699 Points

Why do we use "save-exact" or "-E"?

I am pretty sure that we do --save -E so that we don't worry about future updates breaking our code, but I am not really sure and I was wondering if someone could tell us why we add the "-E"

If we don't do the -E when we save, how does that work as well? Does that simply mean that if someone else is to clone our repository and run npm install, they would install possibly a newer version of the dependency?

If this is the case, should we always run the "-E" no matter what? I have also heard a long time ago, that there is a way to allow for minor updates such as [4.1.1 to upgrade to 4.1.9] or something, so that minor bug fixes happen, but not major game changing ones.

I know this is kind of a lot of questions thrown out there, but just curious is someone is able to explain when, how, and why we would use "-E", something else, or not.