Skip to content

Commit

Permalink
chore: remove unused wee_alloc
Browse files Browse the repository at this point in the history
  • Loading branch information
sunng87 committed Jan 26, 2023
1 parent e029b05 commit d3caa6d
Show file tree
Hide file tree
Showing 2 changed files with 0 additions and 16 deletions.
5 changes: 0 additions & 5 deletions playground/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -19,11 +19,6 @@ wasm-bindgen = "0.2.63"
# code size when deploying.
console_error_panic_hook = { version = "0.1.6", optional = true }

# `wee_alloc` is a tiny allocator for wasm that is only ~1K in code size
# compared to the default allocator's ~10K. It is slower than the default
# allocator, however.
wee_alloc = { version = "0.4.5", optional = true }

gloo-utils = { version = "0.1.5", features = ["serde"] }
handlebars = { path = "../" }
serde_json = "1"
Expand Down
11 changes: 0 additions & 11 deletions playground/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -5,17 +5,6 @@ use handlebars::Handlebars;
use serde_json::Value;
use wasm_bindgen::prelude::*;

// When the `wee_alloc` feature is enabled, use `wee_alloc` as the global
// allocator.
#[cfg(feature = "wee_alloc")]
#[global_allocator]
static ALLOC: wee_alloc::WeeAlloc = wee_alloc::WeeAlloc::INIT;

#[wasm_bindgen]
extern "C" {
fn alert(s: &str);
}

#[wasm_bindgen]
pub fn render(template_str: &str, data: JsValue) -> Result<String, String> {
let hbs = Handlebars::new();
Expand Down

0 comments on commit d3caa6d

Please sign in to comment.