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

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.

主站蜘蛛池模板: 平江县| 卢龙县| 逊克县| 陇南市| 乐昌市| 平凉市| 正镶白旗| 墨竹工卡县| 东山县| 和田市| 阿巴嘎旗| 津市市| 岑巩县| 灵寿县| 祁门县| 青岛市| 漳浦县| 讷河市| 兴和县| 平湖市| 信丰县| 濉溪县| 诸暨市| 依兰县| 青龙| 武山县| 会理县| 柳江县| 瑞安市| 丰镇市| 萨迦县| 泸溪县| 新沂市| 怀集县| 洪泽县| 华宁县| 福建省| 杂多县| 旌德县| 罗平县| 固阳县|