Crate js_sys[−][src]
Bindings to JavaScript’s standard, built-in objects, including their methods and properties.
This does not include any Web, Node, or any other JS environment APIs. Only the things that are guaranteed to exist in the global scope by the ECMAScript standard.
https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects
A Note About camelCase
, snake_case
, and Naming Conventions
JavaScript’s global objects use camelCase
naming conventions for functions
and methods, but Rust style is to use snake_case
. These bindings expose
the Rust style snake_case
name. Additionally, acronyms within a method
name are all lower case, where as in JavaScript they are all upper case. For
example, decodeURI
in JavaScript is exposed as decode_uri
in these
bindings.
Modules
Atomics | The |
Intl | |
JSON | The |
Math | |
Reflect | |
WebAssembly |
Structs
Array | |
ArrayBuffer | |
ArrayIter | Iterator returned by |
AsyncIterator | Any object that conforms to the JS async iterator protocol. For example,
something returned by |
Boolean | |
DataView | |
Date | |
Error | |
EvalError | |
Float32Array | |
Float64Array | |
Function | |
Generator | |
Int8Array | |
Int16Array | |
Int32Array | |
IntoIter | An iterator over the JS |
Iter | An iterator over the JS |
Iterator | Any object that conforms to the JS iterator protocol. For example,
something returned by |
IteratorNext | The result of calling |
JsString | |
Map | |
Number | |
Object | |
Promise | The |
Proxy | |
RangeError | The |
ReferenceError | The |
RegExp | |
Set | |
SharedArrayBuffer | |
Symbol | |
SyntaxError | A |
TypeError | The |
Uint8Array | |
Uint8ClampedArray | |
Uint16Array | |
Uint32Array | |
UriError | The |
WeakMap | |
WeakSet |
Functions
decode_uri | The |
decode_uri_component | The |
encode_uri | The |
encode_uri_component | The |
escape | The |
eval | The |
global | Returns a handle to the global scope object. |
is_finite | The global |
parse_float | The |
parse_int | The |
try_iter | Create an iterator over |
unescape | The |