From adc326139a51079c2b8908a13f5d6a474ca4ee9f Mon Sep 17 00:00:00 2001 From: Hakim El Hattab Date: Wed, 8 Feb 2017 12:56:51 +0100 Subject: update deserialize regex to work with decimals --- js/reveal.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'js') diff --git a/js/reveal.js b/js/reveal.js index 125a7b6..4502919 100644 --- a/js/reveal.js +++ b/js/reveal.js @@ -1230,7 +1230,7 @@ if( value === 'null' ) return null; else if( value === 'true' ) return true; else if( value === 'false' ) return false; - else if( value.match( /^\d+$/ ) ) return parseFloat( value ); + else if( value.match( /^[\d\.]+$/ ) ) return parseFloat( value ); } return value; -- cgit v1.2.3