官术网_书友最值得收藏!

Node Fundamentals – Part 2

In this chapter, we'll continue our discussion on some more node fundamentals. We'll explore yargs, and we'll see how to parse command-line arguments using process.argv and yargs. After that, we'll explore JSON. JSON is nothing more than a string that looks kind of like a JavaScript object, with the notable differences being that it uses double quotes instead of single quotes and all of your property names—like name and age, in this case—require quotes around them. We'll look into how to convert an object into a string, then define that string, use it, and convert it back to an object.

After we've done that, we'll fill out the addNote function. Finally, we'll look into refactor, moving the functionality into individual functions and testing the functionality.

More specifically, we'll go through following topics:

  • yargs
  • JSON
  • Adding note
  • Refactor
主站蜘蛛池模板: 福清市| 五家渠市| 新竹县| 江达县| 武冈市| 汨罗市| 托里县| 蛟河市| 漳浦县| 华蓥市| 砀山县| 邵阳市| 上思县| 郁南县| 会理县| 会东县| 卫辉市| 南平市| 游戏| 新巴尔虎右旗| 青浦区| 五指山市| 雅安市| 莲花县| 石林| 长沙市| 东光县| 昌都县| 抚松县| 德庆县| 冀州市| 浮山县| 安庆市| 嘉兴市| 呼图壁县| 锡林浩特市| 丽江市| 梅州市| 鹿邑县| 克山县| 滨海县|