time-to-botec

Benchmark sampling in different programming languages
Log | Files | Refs | README

repl.txt (1040B)


      1 
      2 {{alias}}( value )
      3     Returns an array of an object's own non-enumerable symbol properties.
      4 
      5     Property order is not guaranteed, as object property enumeration is not
      6     specified according to the ECMAScript specification. In practice, however,
      7     most engines use insertion order to sort an object's properties, thus
      8     allowing for deterministic extraction.
      9 
     10     If provided `null` or `undefined`, the function returns an empty array.
     11 
     12     Parameters
     13     ----------
     14     value: any
     15         Input value.
     16 
     17     Returns
     18     -------
     19     symbols: Array
     20         List of an object's own non-enumerable symbol properties.
     21 
     22     Examples
     23     --------
     24     > var obj = {};
     25     > var desc = {};
     26     > desc.configurable = false;
     27     > desc.enumerable = false;
     28     > desc.writable = true;
     29     > desc.value = 'boop';
     30     > var sym = ( {{alias:@stdlib/symbol/ctor}} ) ? {{alias:@stdlib/symbol/ctor}}( 'beep' ) : 'beep';
     31     > {{alias:@stdlib/utils/define-property}}( obj, sym, desc );
     32     > var symbols = {{alias}}( obj )
     33 
     34     See Also
     35     --------
     36