fn serialize_struct(
    self,
    name: &'static str,
    _len: usize,
  ) -> Result<Self::SerializeStruct> {
    if name == magic::NAME {
      let m = MagicSerializer {
        scope: self.scope,
        v8_value: None,
      };
      return Ok(StructSerializers::Magic(m));
    }
    let o = ObjectSerializer::new(self.scope);
    Ok(StructSerializers::Regular(o))
  }
/// Serialises Rust typed structs into plain JS objects.
Serialises Rust typed structs into plain JS objects.
Serialises Rust typed structs into plain JS objects .
fn serialize_struct(
    self,
    name: &'static str,
    _len: usize,
  ) -> Result<Self::SerializeStruct> {
    if name == magic::NAME {
      let m = MagicSerializer {
        scope: self.scope,
        v8_value: None,
      };
      return Ok(StructSerializers::Magic(m));
    }
    let o = ObjectSerializer::new(self.scope);
    Ok(StructSerializers::Regular(o))
  }
fn serialize_struct ( self , name : & ' static str , _len : usize , ) -> Result < Self :: SerializeStruct > { if name == magic :: NAME { let m = MagicSerializer { scope : self . scope , v8_value : None , } ; return Ok ( StructSerializers :: Magic ( m ) ) ; } let o = ObjectSerializer :: new ( self . scope ) ; Ok ( StructSerializers :: Regular ( o ) ) }
Serialises Rust typed structs into plain JS objects.
Serialises Rust typed structs into plain JS objects .
self
name
&'static str
_len
usize
self
name
&'static str
_len
usize