element

检索数据类型并返回数据类型名称

Source:
Parameters:
Name Type Description
variable Any

要判断的数据

Returns:
Type:
String

数据类型名,具体参考以下 number string boolean null undefined symbol function array object date regexp error ...

Source:
Parameters:
Name Type Description
data Any

被拷贝的数据

Returns:
Type:
Any

返回新的数据

Source:
Parameters:
Name Type Description
参数为object对象 Any
Returns:
Type:
Object

返回一个新的对象

Example
extend({a: 1}, {a: 2, b: 1})   // { a: 2, b: 1 }
Source:
Parameters:
Name Type Description
value *

变量

深拷贝

Source:
Parameters:
Name Type Description
variable Any

要判断的数据

Returns:
Type:
String

数据类型名,具体参考以下 number string boolean null undefined symbol function array object date regexp error ...

Source:
Parameters:
Name Type Description
data Any

被拷贝的数据

Returns:
Type:
Any

返回新的数据

Source:
Parameters:
Name Type Description
参数为object对象 Any
Returns:
Type:
Object

返回一个新的对象

Example
extend({a: 1}, {a: 2, b: 1})   // { a: 2, b: 1 }
Source:
Parameters:
Name Type Description
value *

变量

对象继承添加属性、方法[类继承] Object.assign(...arg)的包装

Source:
Parameters:
Name Type Description
variable Any

要判断的数据

Returns:
Type:
String

数据类型名,具体参考以下 number string boolean null undefined symbol function array object date regexp error ...

Source:
Parameters:
Name Type Description
data Any

被拷贝的数据

Returns:
Type:
Any

返回新的数据

Source:
Parameters:
Name Type Description
参数为object对象 Any
Returns:
Type:
Object

返回一个新的对象

Example
extend({a: 1}, {a: 2, b: 1})   // { a: 2, b: 1 }
Source:
Parameters:
Name Type Description
value *

变量

判断值是否为空 [空的定义有多种]

Source:
Parameters:
Name Type Description
variable Any

要判断的数据

Returns:
Type:
String

数据类型名,具体参考以下 number string boolean null undefined symbol function array object date regexp error ...

Source:
Parameters:
Name Type Description
data Any

被拷贝的数据

Returns:
Type:
Any

返回新的数据

Source:
Parameters:
Name Type Description
参数为object对象 Any
Returns:
Type:
Object

返回一个新的对象

Example
extend({a: 1}, {a: 2, b: 1})   // { a: 2, b: 1 }
Source:
Parameters:
Name Type Description
value *

变量