ark-module 0.17.0-pre.18

Ark Wasm module implementation helper
Documentation
//! # Ark module crate
//!
//! This crate is used at the root level the for building Ark Wasm module binaries.
//! It should not be depended on and used by library crates.
//!
//! Also see the [🗺️ Ark Developer Guide](https://ark.embark.dev/api/ark_api/)

// crate-specific exceptions:
#![deny(
    missing_docs,
    rustdoc::broken_intra_doc_links,
    rustdoc::private_intra_doc_links,
    rustdoc::missing_crate_level_docs
)]
#![forbid(clippy::not_unsafe_ptr_arg_deref)]

#[cfg(target_arch = "wasm32")]
mod types {
    pub mod applet;
    pub mod audio;
    #[cfg(feature = "behavior")]
    pub mod behavior;
    pub mod cmdlet;
    pub mod render;
    #[cfg(feature = "unstable-servlet")]
    pub mod servlet;
}
#[cfg(target_arch = "wasm32")]
pub use types::*;

mod alloc;
#[cfg(target_arch = "wasm32")]
mod log;
#[cfg(target_arch = "wasm32")]
mod panic;

// This is public so the internal macros can access it
#[doc(hidden)]
#[cfg(target_arch = "wasm32")]
pub mod util;

#[cfg(feature = "with_async")]
mod runtime;
#[cfg(feature = "with_async")]
pub use runtime::*;

/// Initialize the module
#[cfg(target_arch = "wasm32")]
pub fn init() {
    log::LOG.activate();
}

// Export log crate macro so we can use it in our own macro
#[doc(hidden)]
pub use ::log::error;
// Export so we can us it in our macros
#[doc(hidden)]
pub use ark_api_ffi::ErrorCode;