Logo
Explore Help
Sign In
fluencelabs/wasm-bindgen
1
0
Fork 0
You've already forked wasm-bindgen
mirror of https://github.com/fluencelabs/wasm-bindgen synced 2025-05-12 13:57:14 +00:00
Code Issues Projects Releases Wiki Activity
wasm-bindgen/examples/asm.js/src/lib.rs

17 lines
267 B
Rust
Raw Normal View History

Remove usage of #[wasm_custom_section] (#509) This has been stabilized on nightly as `#[link_section]`, so no need for an unstable attribute any more. Yay!
2018-07-19 08:57:18 -05:00
#![feature(use_extern_macros, wasm_import_module)]
Add an example of `wasm2asm` and wasm-bindgen This commit adds an example of executing the `wasm2asm` tool to generate asm.js output instead of WebAssembly. This is often useful when supporting older browsers, such as IE 11, that doesn't have native support for WebAssembly.
2018-04-30 13:22:46 -07:00
extern crate wasm_bindgen;
use wasm_bindgen::prelude::*;
#[wasm_bindgen]
rustfmt all the things
2018-06-27 22:42:34 -07:00
extern "C" {
Add an example of `wasm2asm` and wasm-bindgen This commit adds an example of executing the `wasm2asm` tool to generate asm.js output instead of WebAssembly. This is often useful when supporting older browsers, such as IE 11, that doesn't have native support for WebAssembly.
2018-04-30 13:22:46 -07:00
#[wasm_bindgen(js_namespace = console)]
fn log(s: &str);
}
#[wasm_bindgen]
pub fn run() {
log("Hello, World!");
}
Reference in New Issue Copy Permalink
Powered by Gitea Version: 1.23.7 Page: 1011ms Template: 3ms
English
Bahasa Indonesia Deutsch English Español Français Gaeilge Italiano Latviešu Magyar nyelv Nederlands Polski Português de Portugal Português do Brasil Suomi Svenska Türkçe Čeština Ελληνικά Български Русский Українська فارسی മലയാളം 日本語 简体中文 繁體中文(台灣) 繁體中文(香港) 한국어
Licenses API