From 0043f4d1e32b5f17d302e985d697eeda2a3d9d7d Mon Sep 17 00:00:00 2001 From: King Date: Tue, 30 Jan 2018 17:19:23 -0500 Subject: [PATCH] remove new keyword --- snippets/toCurrency.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/snippets/toCurrency.md b/snippets/toCurrency.md index 40cc19b8b..bc690aa68 100644 --- a/snippets/toCurrency.md +++ b/snippets/toCurrency.md @@ -2,10 +2,10 @@ Take a number and return specified currency formatting. -Use `new Intl.NumberFormat` to enable country / currency sensitive formatting. +Use `Intl.NumberFormat` to enable country / currency sensitive formatting. ```js -const toCurrency = (n, curr, LanguageFormat = undefined) => new Intl.NumberFormat(LanguageFormat, { style: 'currency', currency: curr }).format(n); +const toCurrency = (n, curr, LanguageFormat = undefined) => Intl.NumberFormat(LanguageFormat, { style: 'currency', currency: curr }).format(n); ``` ```js