Skip to main content

create_object_lit

Function create_object_lit 

Source
pub fn create_object_lit(props: Vec<PropOrSpread>) -> ObjectLit
Expand description

Creates an ObjectLit from a vector of PropOrSpread.

§Arguments

  • props - The properties to include in the object literal

§Example

let object_lit = create_object_lit(vec![prop_or_spread_factory(key, value)]);