badboy / weedle2

A WebIDL Parser

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

NOTE: Weedle2 moved to the UniFFI repository in April 2022.


Weedle 2 - Electric Boogaloo

A Web IDL parser

Crates.io version Documentation MIT License

Built with 🦀🕸 by The Rust and WebAssembly Working Group.
Forked to extend the functionality beyond WebIDL needs.

About

Parses valid WebIDL definitions & produces a data structure starting from Definitions.

Usage

Cargo.toml

[dependencies]
weedle2 = "2.0.0-alpha0"

src/main.rs

fn main() {
    let parsed = weedle::parse("
        interface Window {
            readonly attribute Storage sessionStorage;
        };
    ").unwrap();

    println!("{:?}", parsed);
}

About

A WebIDL Parser

License:MIT License


Languages

Language:WebIDL 54.6%Language:Rust 45.4%