Here is a snippet of code
str = "a,b,c"; name = str.split(",");
The variable name displayed as the type "object" in Firefox and the type "string" in chrome Why is this happening? Here is jsfiddle http://jsfiddle.net/XujYT/17/
name
The name variable also stores the value "a,b,c" instead of a split array in chrome http://jsfiddle.net/XujYT/23/
"a,b,c"
Because name is a global variable used by chrome and cannot be overridden without unexpected results. Try:
var name = str.split(","); // always use var for local variables!
Source: https://habr.com/ru/post/1446618/More articles:Function call in nested DLL? - c ++wpf DataGrid loses its row selection when focus is lost - wpfOperation can destabilize runtime in ASP.NET - .netPink diagram in R - rclass constructor and object initialization / initialization C ++ / GCC - c ++https://translate.googleusercontent.com/translate_c?depth=1&rurl=translate.google.com&sl=ru&sp=nmt4&tl=en&u=https://fooobar.com/questions/1446619/cc-how-to-get-size-of-directory-where-path-is-too-long-or-permission-denied&usg=ALkJrhg2QtAdzXgqw27buNmSASW-Uug94QPython Smart date parsing without specified year - pythonWinRT Advertising Alternative to Microsoft Pubcenter - windows-8Codeigniter cache files are not deleted - phpGrunt does not work: - bash: exec: grunt: not found - node.jsAll Articles