source, in which the nested value should be set.
path array of the nested value in the source
value to be set in source on specified path
Sets the value on the specified path in source value. If the path in the source doesn't exist it will be created. Note, that we don't know what is the type of the object at runtime. Due to this, if the path value is number, we create an array, otherwise object.
Source value can be nullable or undefinable, and path is treated as if the source (and all intermediate) values are required (because nullable and undefinable types can't have keys).
Path supports up to 5 elements. This means, you are not able to use this helper if you need more.
Return type will be the same as the source type, where any optional values along the path are made required (because they are created).
source value with value on path set
source, in which the nested value should be set.
path array of the nested value in the source
value to be set in source on specified path
Sets the value on the specified path in source value. If the path in the source doesn't exist it will be created. Note, that we don't know what is the type of the object at runtime. Due to this, if the path value is number, we create an array, otherwise object.
Source value can be nullable or undefinable, and path is treated as if the source (and all intermediate) values are required (because nullable and undefinable types can't have keys).
Path supports up to 5 elements. This means, you are not able to use this helper if you need more.
Return type will be the same as the source type, where any optional values along the path are made required (because they are created).
source value with value on path set
source, in which the nested value should be set.
path array of the nested value in the source
value to be set in source on specified path
Sets the value on the specified path in source value. If the path in the source doesn't exist it will be created. Note, that we don't know what is the type of the object at runtime. Due to this, if the path value is number, we create an array, otherwise object.
Source value can be nullable or undefinable, and path is treated as if the source (and all intermediate) values are required (because nullable and undefinable types can't have keys).
Path supports up to 5 elements. This means, you are not able to use this helper if you need more.
Return type will be the same as the source type, where any optional values along the path are made required (because they are created).
source value with value on path set
source, in which the nested value should be set.
path array of the nested value in the source
value to be set in source on specified path
Sets the value on the specified path in source value. If the path in the source doesn't exist it will be created. Note, that we don't know what is the type of the object at runtime. Due to this, if the path value is number, we create an array, otherwise object.
Source value can be nullable or undefinable, and path is treated as if the source (and all intermediate) values are required (because nullable and undefinable types can't have keys).
Path supports up to 5 elements. This means, you are not able to use this helper if you need more.
Return type will be the same as the source type, where any optional values along the path are made required (because they are created).
source value with value on path set
source, in which the nested value should be set.
path array of the nested value in the source
value to be set in source on specified path
Generated using TypeDoc
Sets the value on the specified path in source value. If the path in the source doesn't exist it will be created. Note, that we don't know what is the type of the object at runtime. Due to this, if the path value is number, we create an array, otherwise object.
Source value can be nullable or undefinable, and path is treated as if the source (and all intermediate) values are required (because nullable and undefinable types can't have keys).
Path supports up to 5 elements. This means, you are not able to use this helper if you need more.
Return type will be the same as the source type, where any optional values along the path are made required (because they are created).
Returns
source value with value on path set