From 555743e0c517d0ad8fe63b085bf18557e96ab38f Mon Sep 17 00:00:00 2001 From: Angelos Chalaris Date: Sun, 31 Dec 2017 14:04:44 +0200 Subject: [PATCH] Update memoize.md --- snippets/memoize.md | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) diff --git a/snippets/memoize.md b/snippets/memoize.md index 8a71702e1..c1b6b1343 100644 --- a/snippets/memoize.md +++ b/snippets/memoize.md @@ -2,11 +2,8 @@ Returns the memoized (cached) function. -Use `Object.create(null)` to create an empty object without Object.prototype -(so that those properties are not resolved if the input value is something like 'hasOwnProperty'). -Return a function which takes a single argument to be supplied to the memoized function -by first checking if the function's output for that specific input value is already cached, or -store and return it if not. +Use `Object.create(null)` to create an empty object without `Object.prototype` (so that those properties are not resolved if the input value is something like `'hasOwnProperty'`). +Return a function which takes a single argument to be supplied to the memoized function by first checking if the function's output for that specific input value is already cached, or store and return it if not. ```js const memoize = fn => {