Skip to main content

Crate euv_core

Crate euv_core 

Source
Expand description

euv-core

A declarative, cross-platform UI framework for Rust with virtual DOM, reactive signals, and HTML macros for WebAssembly.

Modules§

Atomics
The Atomics object provides atomic operations as static methods. They are used with SharedArrayBuffer objects.
Intl
JSON
The JSON object contains methods for parsing JavaScript Object Notation (JSON) and converting values to JSON. It can’t be called or constructed, and aside from its two method properties, it has no interesting functionality of its own.
Math
Reflect
WebAssembly
console
futures
Bridging between JavaScript Promises and Rust Futures.
js_sys
Bindings to JavaScript’s standard, built-in objects, including their methods and properties.
self
Utilities for formatting and printing Strings.
wasm_bindgen
Runtime support for the wasm-bindgen tool

Structs§

AggregateError
The AggregateError object represents an error when several errors need to be wrapped in a single error. It is thrown when multiple errors need to be reported by an operation, for example by Promise::any, when all promises passed to it reject.
AnimationEvent
The AnimationEvent class.
App
A zero-sized application context struct providing access to core euv framework APIs.
Array
ArrayBuffer
ArrayBufferOptions
ArrayIntoIter
Iterator returned by Array::into_iter
ArrayIter
Iterator returned by Array::iter
ArrayTuple
AssertUnwindSafe
A simple wrapper around a type to assert that it is unwind safe.
AsyncGenerator
AsyncIterator
Any object that conforms to the JS async iterator protocol. For example, something returned by myObject[Symbol.asyncIterator]().
AttrValueAdapter
Adapts an arbitrary attribute value expression into an AttributeValue.
AttributeEntry
Represents a single attribute on a virtual DOM node.
AudioBuffer
The AudioBuffer class.
AudioBufferSourceNode
The AudioBufferSourceNode class.
AudioContext
The AudioContext class.
AudioDestinationNode
The AudioDestinationNode class.
AudioListener
The AudioListener class.
AudioNode
The AudioNode class.
AudioParam
The AudioParam class.
AudioScheduledSourceNode
The AudioScheduledSourceNode class.
BaseAudioContext
The BaseAudioContext class.
BeforeUnloadEvent
The BeforeUnloadEvent class.
BigInt
BigInt64Array
BigUint64Array
Blob
The Blob class.
Boolean
CallbackNamedAdapter
Adapts a callback with a custom name into an AttributeValue.
CanvasGradient
The CanvasGradient class.
CanvasRenderingContext2d
The CanvasRenderingContext2d class.
CharacterData
The CharacterData class.
Charset
Handles string encoding and decoding operations.
Clipboard
The Clipboard class.
ClipboardEvent
The ClipboardEvent class.
Css
Represents a CSS class with a name, its style declarations, and optional pseudo rules.
CssStyleDeclaration
The CssStyleDeclaration class.
DataTransfer
The DataTransfer class.
DataView
Date
DefaultHasher
The default Hasher used by RandomState.
Document
The Document class.
DocumentFragment
The DocumentFragment class.
DomRect
The DomRect class.
DomRectReadOnly
The DomRectReadOnly class.
DragEvent
The DragEvent class.
DynamicNode
A closure-based dynamic node that re-renders when its dependency signals change.
Element
The Element class.
Error
ErrorOptions
The options dictionary accepted as the second argument to the Error constructor (and other built-in error constructors such as AggregateError). Its sole standard property is cause, which indicates the original cause of the error.
EvalError
Event
The Event class.
EventAdapter
Adapts various event value types into an AttributeValue for event attributes.
EventInit
The EventInit dictionary.
EventNamedAdapter
Adapts an event with a specific event name into an AttributeValue.
EventSource
The EventSource class.
EventTarget
The EventTarget class.
File
The File class.
FileList
The FileList class.
FileReader
The FileReader class.
FinalizationRegistry
The FinalizationRegistry object lets you request a callback when an object is garbage-collected.
FireHandle
A handle to a leaked FnMut() closure, stored as the closure’s heap address.
Float16Array
Float32Array
Float64Array
FocusEvent
The FocusEvent class.
Formatter
Configuration for formatting.
Function
Function represents any generic Function in JS, by treating all arguments as JsValue.
GainNode
The GainNode class.
Gamepad
The Gamepad class.
GamepadButton
The GamepadButton class.
GamepadEvent
The GamepadEvent class.
Generator
HashChangeEvent
The HashChangeEvent class.
HashMap
A hash map implemented with quadratic probing and SIMD lookup.
HashSet
A hash set implemented as a HashMap where the value is ().
History
The History class.
HookContext
Manages hook state across render cycles for a DynamicNode.
HookContextInner
Internal storage for hook state, holding boxed Any values.
HtmlButtonElement
The HtmlButtonElement class.
HtmlCanvasElement
The HtmlCanvasElement class.
HtmlCollection
The HtmlCollection class.
HtmlElement
The HtmlElement class.
HtmlFormElement
The HtmlFormElement class.
HtmlHeadElement
The HtmlHeadElement class.
HtmlImageElement
The HtmlImageElement class.
HtmlInputElement
The HtmlInputElement class.
HtmlMediaElement
The HtmlMediaElement class.
HtmlMetaElement
The HtmlMetaElement class.
HtmlOptionElement
The HtmlOptionElement class.
HtmlSelectElement
The HtmlSelectElement class.
HtmlStyleElement
The HtmlStyleElement class.
HtmlTextAreaElement
The HtmlTextAreaElement class.
HtmlVideoElement
The HtmlVideoElement class.
ImageData
The ImageData class.
InnerHtmlAdapter
Adapts an inner_html: payload into the matching AttributeValue variant (InnerHtml(String) for static strings, InnerHtmlSignal for Signal<String>).
InputEvent
The InputEvent class.
Int8Array
Int16Array
Int32Array
IntersectionObserver
The IntersectionObserver class.
IntersectionObserverEntry
The IntersectionObserverEntry class.
IntersectionObserverInit
The IntersectionObserverInit dictionary.
IntervalHandle
A handle to a browser interval timer created by use_interval.
IntoIter
An iterator over the JS Symbol.iterator iteration protocol.
Iter
An iterator over the JS Symbol.iterator iteration protocol.
Iterator
Any object that conforms to the JS iterator protocol. For example, something returned by myArray[Symbol.iterator]().
IteratorNext
The result of calling next() on a JS iterator.
JsError
Convenience type for use on exported fn() -> Result<T, JsError> functions, where you wish to throw a JavaScript Error object.
JsNullable
A nullable JS value of type T.
JsOption
An optional JS value of type T.
JsString
JsValue
Representation of an object owned by JS.
KeyboardEvent
The KeyboardEvent class.
LazyLock
A value which is initialized on the first access.
LocalKey
A thread local storage (TLS) key which owns its contents.
Location
The Location class.
LruCache
A fixed-capacity LRU cache.
Map
MediaDevices
The MediaDevices class.
MediaQueryList
The MediaQueryList class.
MediaRule
Represents a CSS @media rule attached to a class.
MediaStream
The MediaStream class.
MediaStreamConstraints
The MediaStreamConstraints dictionary.
MediaStreamTrack
The MediaStreamTrack class.
MessageEvent
The MessageEvent class.
MouseEvent
The MouseEvent class.
NativeEventHandler
A wrapper around an event callback.
Navigator
The Navigator class.
Node
The Node class.
NodeList
The NodeList class.
NodeRef
A reactive handle to a mounted DOM element.
Null
The JavaScript null value.
Number
Object
OnceLock
A synchronization primitive which can nominally be written to only once.
Performance
The Performance class.
PhantomData
Zero-sized type used to mark things that “act like” they own a T.
Promise
The Promise object represents the eventual completion (or failure) of an asynchronous operation, and its resulting value.
PromiseState
The PromiseState object represents the the status of the promise, as used in allSettled.
PropertyDescriptor
Proxy
PseudoRule
Represents a CSS pseudo-class or pseudo-element rule attached to a class.
RangeError
The RangeError object indicates an error when a value is not in the set or range of allowed values.
RawHtml
A raw HTML string that the renderer must insert without escaping.
ReferenceError
The ReferenceError object represents an error when a non-existent variable is referenced.
RegExp
RegExpMatchArray
The result array from RegExp.exec() or String.matchAll().
ResizeObserver
The ResizeObserver class.
ResizeObserverEntry
The ResizeObserverEntry class.
Response
The Response class.
RwLock
A reader-writer lock
RwLockReadGuard
RAII structure used to release the shared read access of a lock when dropped.
ScopedClosure
A closure with a lifetime parameter that represents a Rust closure passed to JavaScript.
ScrollIntoViewOptions
The ScrollIntoViewOptions dictionary.
Set
SharedArrayBuffer
Signal
A reactive signal handle.
SignalCell
A Sync wrapper for single-threaded global Signal access.
Storage
The Storage class.
SubmitEvent
The SubmitEvent class.
Symbol
SyntaxError
A SyntaxError is thrown when the JavaScript engine encounters tokens or token order that does not conform to the syntax of the language when parsing code.
SystemTime
The wall clock [now_micros] reads on a host build. On wasm the clock comes from JS instead, so importing this there is an unused_imports warning — the mirror of the dead-const warning the host build would give the other half of the same function. A measurement of the system clock, useful for talking to external entities like the file system or other processes.
Text
The Text class.
TextNode
Represents a text node in the virtual DOM.
Touch
The Touch class.
TouchEvent
The TouchEvent class.
TouchList
The TouchList class.
TransitionEvent
The TransitionEvent class.
TryFromIntError
The error type returned when a checked integral type conversion fails.
TypeError
The TypeError object represents an error when a value is not of the expected type.
UiEvent
The UiEvent class.
Uint8Array
Uint8ClampedArray
Uint16Array
Uint32Array
Undefined
The JavaScript undefined value.
UriError
The URIError object represents an error when a global URI handling function was used in a wrong way.
VecDeque
A double-ended queue implemented with a growable ring buffer.
VisualViewport
The VisualViewport class.
WeakMap
WeakRef
WeakSet
WebGl2RenderingContext
The WebGl2RenderingContext class.
WebGlBuffer
The WebGlBuffer class.
WebGlContextAttributes
The WebGlContextAttributes dictionary.
WebGlFramebuffer
The WebGlFramebuffer class.
WebGlProgram
The WebGlProgram class.
WebGlRenderbuffer
The WebGlRenderbuffer class.
WebGlShader
The WebGlShader class.
WebGlTexture
The WebGlTexture class.
WebGlUniformLocation
The WebGlUniformLocation class.
WebGlVertexArrayObject
The WebGlVertexArrayObject class.
WebSocket
The WebSocket class.
WheelEvent
The WheelEvent class.
Window
The Window class.

Enums§

AttributeValue
Represents the value of an HTML attribute.
Cow
A clone-on-write smart pointer.
EncodeError
Represents errors that can occur during encoding.
ScrollBehavior
The ScrollBehavior enum.
ScrollLogicalPosition
The ScrollLogicalPosition enum.
Tag
Represents the type of an HTML tag or a component.
VirtualNode
Represents a node in the virtual DOM tree.

Constants§

UNIX_EPOCH
The wall clock [now_micros] reads on a host build. On wasm the clock comes from JS instead, so importing this there is an unused_imports warning — the mirror of the dead-const warning the host build would give the other half of the same function. An anchor in time which can be used to create new SystemTime instances or learn about where in time a SystemTime lies.

Traits§

AsReactiveText
Trait for types that can be converted into a reactive text VirtualNode.
AsyncIterable
Trait for types known to implement the iterator protocol on Symbol.asyncIterator
Debug
? formatting.
Display
Format trait for an empty format, {}.
FunctionIntoClosure
Hash
A hashable type.
Hasher
A trait for hashing an arbitrary stream of bytes.
IntoJsGeneric
Value conversion from a type into its canonical JsGeneric form.
Iterable
Trait for JavaScript types that implement the iterable protocol via Symbol.iterator.
JsArgs
Trait for argument tuples that can call or bind a Function<T>.
JsCast
A trait for dynamic checked and unchecked casting between JS types.
JsFunction
JsFunction1
JsFunction2
JsFunction3
JsFunction4
JsFunction5
JsFunction6
JsFunction7
JsFunction8
JsGeneric
A convenience trait for types that erase to JsValue.
JsTuple
Base trait for tuple types.
JsTuple1
JsTuple2
JsTuple3
JsTuple4
JsTuple5
JsTuple6
JsTuple7
JsTuple8
Promising
Marker trait for types which represent Resolution or Promise<Resolution>.
TypedArray
UnwrapThrowExt
An extension trait for Option<T> and Result<T, E> for unwrapping the T value, or throwing a JS error if it is not available.
Upcast
A trait for type-safe generic upcasting.

Functions§

catch_unwind
Invokes a closure, capturing the cause of an unwinding panic if one occurs.
decode_uri
The decodeURI() function decodes a Uniform Resource Identifier (URI) previously created by encodeURI or by a similar routine.
decode_uri_component
The decodeURIComponent() function decodes a Uniform Resource Identifier (URI) component previously created by encodeURIComponent or by a similar routine.
encode_uri
The encodeURI() function encodes a Uniform Resource Identifier (URI) by replacing each instance of certain characters by one, two, three, or four escape sequences representing the UTF-8 encoding of the character (will only be four escape sequences for characters composed of two “surrogate” characters).
encode_uri_component
The encodeURIComponent() function encodes a Uniform Resource Identifier (URI) component by replacing each instance of certain characters by one, two, three, or four escape sequences representing the UTF-8 encoding of the character (will only be four escape sequences for characters composed of two “surrogate” characters).
escape
The escape() function computes a new string in which certain characters have been replaced by a hexadecimal escape sequence.
eval
The eval() function evaluates JavaScript code represented as a string.
global
Returns a handle to the global scope object.
is_finite
The global isFinite() function determines whether the passed value is a finite number. If needed, the parameter is first converted to a number.
parse_float
The parseFloat() function parses an argument and returns a floating point number, or NaN on error.
parse_int
The parseInt() function parses a string argument and returns an integer of the specified radix (the base in mathematical numeral systems), or NaN on error.
swap
Swaps the values at two mutable locations, without deinitializing either one.
take
Replaces dest with the default value of T, returning the previous dest value.
try_iter
Create an iterator over val using the JS iteration protocol and Symbol.iterator.
unescape
The unescape() function computes a new string in which hexadecimal escape sequences are replaced with the character that it represents. The escape sequences might be introduced by a function like escape. Usually, decodeURI or decodeURIComponent are preferred over unescape.
window
Getter for the Window object
zeroed⚠
Returns the value of type T represented by the all-zero byte-pattern.

Type Aliases§

Closure
Alias for ScopedClosure<'static, T> for backwards compatibility.
EventCallback
Type alias for an event callback closure.
NodeRefDyn
Type-erased clone-able handle to a DOM element, used as the payload of AttributeValue::Ref so the renderer can populate the ref without committing to a concrete element type at attribute-set time.
SharedEventCallback
Type alias for the shared, interior-mutable storage of an event callback.
TextNodeBinder

Attribute Macros§

__wasm_bindgen_class_marker
wasm_bindgen
A list of all the attributes can be found here: https://wasm-bindgen.github.io/wasm-bindgen/reference/attributes/index.html

Derive Macros§

CustomDebug
A procedural macro that implements the std::fmt::Debug trait for a type, with support for the #[debug(skip)] attribute to skip specific fields.
Data
A procedural macro that combines getter, mutable getter, and setter functionality in a single derive.
Debug
Derive macro generating an impl of the trait Debug.
DisplayDebug
A procedural macro that implements the std::fmt::Display trait for a type, using the standard debug format ({:?}) for formatting.
DisplayDebugFormat
A procedural macro that implements the std::fmt::Display trait for a type, using the detailed debug format ({:#?}) for formatting.
Getter
A procedural macro that automatically generates getter methods for struct and enum fields.
GetterMut
A procedural macro that automatically generates mutable getter methods for struct and enum fields.
Hash
Derive macro generating an impl of the trait Hash.
New
A procedural macro that generates a constructor function for structs.
Setter
A procedural macro that automatically generates setter methods for struct and enum fields.