rdom/
error.rs

1//! Errors that may occur while using rdom.
2
3use thiserror::Error as ThisError;
4
5/// A static rendering DOM exception
6#[derive(Debug, ThisError)]
7pub enum DomError {
8    /// Received an invalid query selector. Static rendering only supports
9    /// "body" and "html".
10    #[error("invalid query selector")]
11    InvalidQuerySelector,
12
13    /// The object being operated on was created in a sandbox that has since
14    /// disappeared.
15    #[error("the sandbox was dropped")]
16    SandboxDropped,
17
18    /// The object being operated on is out of memory. This does not mean the
19    /// sandbox as a whole is out of memory.
20    #[error("object out of memory")]
21    ObjectOutOfMemory,
22}