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

Thinking Functionally - A First Example

In chapter 1, Becoming Functional - Several Questions, we went over what FP is, mentioned some advantages of applying it, and listed some tools we'd be needing in JS... but let's now leave theory behind, and start out by considering a simple problem, and how to solve it in a functional way.

In this chapter, we will see:

  • A simple, common, e-commerce related problem
  • Several usual ways to solve it, with their associated defects
  • A way to solve the problem by looking at it functionally
  • A higher-order solution, which can be applied to other problems
  • How to do unit testing for the functional solutions

In future chapters, We'll be coming back to some of the topics listed here, so we won't be getting very much into details. We'll just show how FP can give a different outlook for our problem, and leave further details for afterward.

主站蜘蛛池模板: 根河市| 梨树县| 济宁市| 巴彦县| 杭锦旗| 龙泉市| 德保县| 清河县| 西平县| 贵德县| 织金县| 台南市| 齐齐哈尔市| 仁怀市| 和静县| 安溪县| 江津市| 永定县| 靖安县| 东台市| 宜州市| 静安区| 静海县| 兴宁市| 漳州市| 阜康市| 宜宾市| 双辽市| 二连浩特市| 于田县| 三门县| 长顺县| 洛隆县| 宜宾市| 邓州市| 手游| 台东县| 伊吾县| 长岛县| 新巴尔虎右旗| 嘉荫县|