Skip to content

Commit c1d63d1

Browse files
committed
rename ids for debugging
1 parent 3bdd1f0 commit c1d63d1

File tree

1 file changed

+21
-21
lines changed

1 file changed

+21
-21
lines changed

coderoad-config.json

+21-21
Original file line numberDiff line numberDiff line change
@@ -24,22 +24,22 @@
2424
},
2525
"levels": [
2626
{
27-
"id": "mJF4OxtB6",
27+
"id": "L1",
2828
"title": "Intro",
2929
"summary": "Introduction to the package.json",
3030
"content": "When starting a new project, NPM generates a package.json file. This file lists the package dependencies for your project. Since NPM packages are regularly updated, the package.json file allows you to set specific version numbers for each dependency. This ensures that updates to a package don't break your project.\n\nNPM saves packages in a folder named node_modules. These packages can be installed in two ways:\n\n- globally in a root node_modules folder, accessible by all projects.\n- locally within a project's own node_modules folder, accessible only to that project.\n\nMost developers prefer to install packages local to each project to create a separation between the dependencies of different projects.\n\nThe `package.json` file is the center of any Node.js project or NPM package. It stores information about your project, similar to how the <head> section of an HTML document describes the content of a webpage. It consists of a single JSON object where information is stored in key-value pairs. There are only two required fields; \"name\" and \"version\", but it’s good practice to provide additional information about your project that could be useful to future users or maintainers.\nIf you look at the file tree of your project, you will find the package.json file on the top level of the tree. This is the file that you will be improving in the next couple of challenges.\n",
3131
"setup": null,
3232
"steps": []
3333
},
3434
{
35-
"id": "9ZasbWt6gy",
35+
"id": "L2",
3636
"title": "Author",
3737
"summary": "Package.json author",
3838
"content": "One of the most common pieces of information in this file is the `author` field. It specifies who created the project, and can consist of a string or an object with contact or other details. An object is recommended for bigger projects, but a simple string like the following example will do for this project.\n\n```json\n\"author\": \"Jane Doe\",\n```\n",
3939
"setup": null,
4040
"steps": [
4141
{
42-
"id": "bCzlTigHAL",
42+
"id": "L2:S1",
4343
"setup": {
4444
"files": ["package.json"],
4545
"commits": ["c3b4350"],
@@ -54,14 +54,14 @@
5454
]
5555
},
5656
{
57-
"id": "q6oQ17ABNl",
57+
"id": "L3",
5858
"title": "Description",
5959
"summary": "Package.json description",
6060
"content": "The next part of a good package.json file is the `description` field; where a short, but informative description about your project belongs.\nIf you some day plan to publish a package to NPM, this is the string that should sell your idea to the user when they decide whether to install your package or not. However, that’s not the only use case for the description, it’s a great way to summarize what a project does. It’s just as important in any Node.js project to help other developers, future maintainers or even your future self understand the project quickly.\n\nRegardless of what you plan for your project, a description is definitely recommended.\n\nHere's an example:\n\n```json\n\"description\": \"A project that does something awesome\",\n```\n",
6161
"setup": null,
6262
"steps": [
6363
{
64-
"id": "qtyop7mIYu",
64+
"id": "L3:S1",
6565
"setup": {
6666
"files": ["package.json"],
6767
"commits": ["1917199"]
@@ -75,14 +75,14 @@
7575
]
7676
},
7777
{
78-
"id": "L5--vbS9sK",
78+
"id": "L4",
7979
"title": "Keywords",
8080
"summary": "Package.json keywords",
8181
"content": "The `keywords` field is where you can describe your project using related keywords.\n\nHere's an example:\n\n```json\n\"keywords\": [ \"descriptive\", \"related\", \"words\" ],\n```\n\nAs you can see, this field is structured as an array of double-quoted strings.\n",
8282
"setup": null,
8383
"steps": [
8484
{
85-
"id": "-dUCTOVbdo",
85+
"id": "L4:S1",
8686
"setup": {
8787
"files": ["package.json"],
8888
"commits": ["2ba75f8"]
@@ -96,14 +96,14 @@
9696
]
9797
},
9898
{
99-
"id": "KB-FXNFfMM",
99+
"id": "L5",
100100
"title": "License",
101101
"summary": "Package.json license",
102102
"content": "The `license` field is where you inform users of what they are allowed to do with your project.\n\nSome common licenses for open source projects include MIT and BSD. License information is not required, and copyright laws in most countries will give you ownership of what you create by default. However, it’s always a good practice to explicitly state what users can and can’t do. Here's an example of the license field:\n\n```json\n\"license\": \"MIT\",\n```\n",
103103
"setup": null,
104104
"steps": [
105105
{
106-
"id": "3DsFYGvBuc",
106+
"id": "L5:S1",
107107
"setup": {
108108
"files": ["package.json"],
109109
"commits": ["acd63ba"]
@@ -117,14 +117,14 @@
117117
]
118118
},
119119
{
120-
"id": "ivRSejLVDM",
120+
"id": "L6",
121121
"title": "Version",
122122
"summary": "Package.json version",
123123
"content": "A `version` is one of the required fields of your package.json file. This field describes the current version of your project. Here's an example:\n\n```json\n\"version\": \"1.2.0\",\n```\n",
124124
"setup": null,
125125
"steps": [
126126
{
127-
"id": "B07NvoYTwI",
127+
"id": "L6:S1",
128128
"setup": {
129129
"files": ["package.json"],
130130
"commits": ["580d786"]
@@ -138,14 +138,14 @@
138138
]
139139
},
140140
{
141-
"id": "qipAhsvVbu",
141+
"id": "L7",
142142
"title": "External Packages",
143143
"summary": "Installing dependencies from NPM",
144144
"content": "One of the biggest reasons to use a package manager, is their powerful dependency management. Instead of manually having to make sure that you get all dependencies whenever you set up a project on a new computer, NPM automatically installs everything for you. But how can NPM know exactly what your project needs? Meet the `dependencies` section of your package.json file.\n\nIn this section, packages your project requires are stored using the following format:\n\n```json\n\"dependencies\": {\n \"package-name\": \"version\",\n \"express\": \"4.17.0\"\n}\n```\n\nInstall a package by running the NPM command line tool in a terminal with the command `install`.\n\n```shell\nnpm install express\n```\n\n**Note:** Use the Use the `⌃\\`` keyboard shortcut with the backtick character to open the VSCode integrated terminal.\n\nInstalled packages are created in a `node_modules` folder in your project. Avoid editing or changing the node_modules folder or its contents.\n",
145145
"setup": null,
146146
"steps": [
147147
{
148-
"id": "9VFvL2uElS",
148+
"id": "L7:S1",
149149
"setup": {
150150
"files": ["package.json"],
151151
"commits": ["eafc39a"],
@@ -160,14 +160,14 @@
160160
]
161161
},
162162
{
163-
"id": "K_kGUiOnH1",
163+
"id": "L8",
164164
"title": "Semantic Versioning",
165165
"summary": "Versioning packages",
166166
"content": "`Versions` of the npm packages in the dependencies section of your package.json file follow what’s called Semantic Versioning (SemVer), an industry standard for software versioning aiming to make it easier to manage dependencies. Libraries, frameworks or other tools published on npm should use SemVer in order to clearly communicate what kind of changes projects can expect if they update.\n\nKnowing SemVer can be useful when you develop software that uses external dependencies (which you almost always do). One day, your understanding of these numbers will save you from accidentally introducing breaking changes to your project without understanding why things that worked yesterday suddenly don’t work today. This is how Semantic Versioning works according to the official website:\n\n```json\n\"package\": \"MAJOR.MINOR.PATCH\"\n```\n\nThe MAJOR version should increment when you make incompatible API changes.\n\nThe MINOR version should increment when you add functionality in a backwards-compatible manner.\n\nThe PATCH version should increment when you make backwards-compatible bug fixes.\nThis means that PATCHes are bug fixes and MINORs add new features but neither of them break what worked before. Finally, MAJORs add changes that won’t work with earlier versions.\n\nUsing the NPM cli, a specific version of a package can be installed by specifying the `@` version.\n\n```shell\nnpm install express@4.17.0\n```\n",
167167
"setup": null,
168168
"steps": [
169169
{
170-
"id": "p_BHY4SsgA",
170+
"id": "L8:S1",
171171
"setup": {
172172
"files": ["package.json"],
173173
"commits": ["e658c66"],
@@ -182,14 +182,14 @@
182182
]
183183
},
184184
{
185-
"id": "dPBnYB5Iqh",
185+
"id": "L9",
186186
"title": "Receive Patch Updates",
187187
"summary": "Using `~` to recieve patches",
188188
"content": "In the last challenge, you told npm to only include a specific version of a package. That’s a useful way to freeze your dependencies if you need to make sure that different parts of your project stay compatible with each other. But in most use cases, you don’t want to miss bug fixes since they often include important security patches and (hopefully) don’t break things in doing so.\n\nTo allow an npm dependency to update to the latest PATCH version, you can prefix the dependency’s version with the tilde (`~`) character. Here's an example of how to allow updates to any 1.3.x version.\n\n```json\n\"package\": \"~1.3.8\"\n```\n",
189189
"setup": null,
190190
"steps": [
191191
{
192-
"id": "BISIX4-iz4d",
192+
"id": "L9:S1",
193193
"setup": {
194194
"files": ["package.json"],
195195
"commits": ["b4edb0c"]
@@ -203,14 +203,14 @@
203203
]
204204
},
205205
{
206-
"id": "LaUEb1VCROB",
206+
"id": "L10",
207207
"title": "Receive Minor Updates",
208208
"summary": "Using `^` to receive minor updates",
209209
"content": "Similar to how the tilde we learned about in the last challenge allows npm to install the latest PATCH for a dependency, the caret (`^`) allows npm to install future updates as well. The difference is that the caret will allow both MINOR updates and PATCHes.\n\nYour current version of moment should be \"~2.10.2\" which allows npm to install to the latest 2.10.x version. If you were to use the caret (`^`) as a version prefix instead, npm would be allowed to update to any 2.x.x version.\n\n```json\n\"package\": \"^1.3.8\"\n```\n\nThis would allow updates to any 1.x.x version of the package.\n",
210210
"setup": null,
211211
"steps": [
212212
{
213-
"id": "X7yBkeKqF6_",
213+
"id": "L10:S1",
214214
"setup": {
215215
"files": ["package.json"],
216216
"commits": ["67c5f7b"]
@@ -224,14 +224,14 @@
224224
]
225225
},
226226
{
227-
"id": "TgbQzyrNnhK",
227+
"id": "L11",
228228
"title": "Remove a Dependency",
229229
"summary": "Removing a dependency",
230230
"content": "You have now tested a few ways you can manage dependencies of your project by using the package.json's dependencies section. You have also included external packages by adding them to the file and even told npm what types of versions you want, by using special characters such as the tilde or the caret.\n\nBut what if you want to remove an external package that you no longer need? You might already have guessed it, just remove the corresponding key-value pair for that package from your dependencies.\n\nThis same method applies to removing other fields in your package.json as well.\n",
231231
"setup": null,
232232
"steps": [
233233
{
234-
"id": "_BvPBHOIDjP",
234+
"id": "L11:S1`",
235235
"setup": {
236236
"files": ["package.json"],
237237
"commits": ["4359bde"]

0 commit comments

Comments
 (0)