-
Notifications
You must be signed in to change notification settings - Fork 5
/
Copy pathCargo.toml
62 lines (52 loc) · 1.96 KB
/
Cargo.toml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
[package]
name = "rhai-playground"
description = "Rhai Playground"
version = "0.2.0"
authors = ["Alvin Wong <[email protected]>"]
categories = ["wasm"]
readme = "README.md"
edition = "2018"
publish = false
[lib]
crate-type = ["cdylib"]
[profile.release]
# This makes the compiled code faster and smaller, but it makes compiling slower,
# so it's only enabled in release mode.
lto = true
codegen-units = 1
opt-level = 's'
[features]
# If you uncomment this line, it will enable `wee_alloc`:
#default = ["wee_alloc"]
[dependencies]
rhai = { version = "1.12.0", features = ["only_i64", "internals", "wasm-bindgen"] }
js-sys = "0.3"
serde = { version = "1.0", features = ["derive"] }
instant = { version = "0.1", features = ["wasm-bindgen"] }
# The `wasm-bindgen` crate provides the bare minimum functionality needed
# to interact with JavaScript.
wasm-bindgen = { version = "0.2.45", features = ["serde-serialize"] }
# `wee_alloc` is a tiny allocator for wasm that is only ~1K in code size
# compared to the default allocator's ~10K. However, it is slower than the default
# allocator, so it's not enabled by default.
wee_alloc = { version = "0.4.2", optional = true }
# The `web-sys` crate allows you to interact with the various browser APIs,
# like the DOM.
[dependencies.web-sys]
version = "0.3.22"
features = ["console"]
# The `console_error_panic_hook` crate provides better debugging of panics by
# logging them with `console.error`. This is great for development, but requires
# all the `std::fmt` and `std::panicking` infrastructure, so it's only enabled
# in debug mode.
[target."cfg(debug_assertions)".dependencies]
console_error_panic_hook = "0.1.5"
# These crates are used for running unit tests.
[dev-dependencies]
wasm-bindgen-test = "0.3.0"
futures = "0.3.0"
js-sys = "0.3.22"
wasm-bindgen-futures = "0.4.0"
[package.metadata.wasm-pack.profile.release]
# See https://github.com/rustwasm/wasm-pack/issues/886#issuecomment-667669802
wasm-opt = ["-Oz", "--enable-mutable-globals"]