mirror of
https://github.com/coderaiser/cloudcmd.git
synced 2026-01-23 10:45:47 +00:00
chore(polyfill) es2015-ify
This commit is contained in:
parent
ed5aeff441
commit
0cea45164e
1 changed files with 7 additions and 6 deletions
|
|
@ -14,7 +14,7 @@ if (!Array.isArray)
|
|||
* https://gist.github.com/2581101
|
||||
*/
|
||||
DOM.scrollIntoViewIfNeeded = function(element, centerIfNeeded) {
|
||||
var parent,
|
||||
let parent,
|
||||
topWidth,
|
||||
leftWidth,
|
||||
parentComputedStyle,
|
||||
|
|
@ -87,13 +87,14 @@ if (!window.JSON) {
|
|||
|
||||
/* https://gist.github.com/754454 */
|
||||
window.JSON.stringify = function(obj) {
|
||||
var n, v, has,
|
||||
let n, v, has,
|
||||
ret = '',
|
||||
value = '',
|
||||
json = [],
|
||||
isStr = itype.string(obj),
|
||||
isObj = itype.object(obj),
|
||||
isArray = itype.array(obj);
|
||||
json = [];
|
||||
|
||||
let isStr = itype.string(obj);
|
||||
let isObj = itype.object(obj);
|
||||
let isArray = itype.array(obj);
|
||||
|
||||
if (!isObj || obj === null) {
|
||||
// simple data type
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue