FFC Back End 1 Flashcards

1
Q

What do the version numbers for a node package mean ? What is the official name for this system?

A

The numbers represent major, minor and patch.

“package”: “MAJOR.MINOR.PATCH”

This is called Semantic Versioning and allows you to predict how big a change a new version of a package will be.

  1. 1.1 to 1.1.3 will only be a small patch change.
  2. 1.1 to 2.0.0 will be a major change and will likely come with breaking changes.
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
2
Q

What does the tilde mean in the following dependency?

“package”: “~1.3.8”

A

It allows an npm dependency to update to the latest PATCH version.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
3
Q

What does the caret mean in the following dependency?

“package”: “^1.3.8”

A

When you use a caret (^) as a version prefix, npm is allowed to update to any 1.x.x version.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
4
Q

How do you remove a node package you no longer need?

A

Just remove the corresponding key-value pair for that package from your dependencies.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly