Skip to content

Commit 2824f03

Browse files
committed
wasm tests
1 parent eb8437c commit 2824f03

File tree

10 files changed

+615
-14
lines changed

10 files changed

+615
-14
lines changed

.gitignore

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,4 +6,6 @@ dist
66
babel-dist
77
pkg
88
pkg.zip
9-
.DS_Store
9+
.DS_Store
10+
crate/target
11+
crate/pkg

README.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -50,7 +50,7 @@ Names:
5050
❌ Invent / Implement license mechanism
5151
- try webassembly
5252

53-
❌ Add support for proposal syntaxes
53+
Add support for proposal syntaxes
5454

5555
✅ Add support for multiple wildcards
5656
- `($$, $$) => {}` is invalid while parsing function
@@ -212,7 +212,7 @@ ___
212212
- Company $29 / month
213213
- up to 10 users (+$3 for each additional user)
214214
- all the above + eslint rules
215-
215+
216216

217217
💡 Product website
218218
- home

crate/Cargo.lock

Lines changed: 288 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

crate/cargo.toml

Lines changed: 51 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,51 @@
1+
# You must change these to your own details.
2+
[package]
3+
name = "rust-webpack-template"
4+
description = "My super awesome Rust, WebAssembly, and Webpack project!"
5+
version = "0.1.0"
6+
authors = ["You <you@example.com>"]
7+
categories = ["wasm"]
8+
readme = "README.md"
9+
edition = "2018"
10+
11+
[lib]
12+
crate-type = ["cdylib"]
13+
14+
[profile.release]
15+
# This makes the compiled code faster and smaller, but it makes compiling slower,
16+
# so it's only enabled in release mode.
17+
lto = true
18+
19+
[features]
20+
# If you uncomment this line, it will enable `wee_alloc`:
21+
#default = ["wee_alloc"]
22+
23+
[dependencies]
24+
# The `wasm-bindgen` crate provides the bare minimum functionality needed
25+
# to interact with JavaScript.
26+
wasm-bindgen = "0.2.45"
27+
28+
# `wee_alloc` is a tiny allocator for wasm that is only ~1K in code size
29+
# compared to the default allocator's ~10K. However, it is slower than the default
30+
# allocator, so it's not enabled by default.
31+
wee_alloc = { version = "0.4.2", optional = true }
32+
33+
# The `web-sys` crate allows you to interact with the various browser APIs,
34+
# like the DOM.
35+
[dependencies.web-sys]
36+
version = "0.3.22"
37+
features = ["console"]
38+
39+
# The `console_error_panic_hook` crate provides better debugging of panics by
40+
# logging them with `console.error`. This is great for development, but requires
41+
# all the `std::fmt` and `std::panicking` infrastructure, so it's only enabled
42+
# in debug mode.
43+
[target."cfg(debug_assertions)".dependencies]
44+
console_error_panic_hook = "0.1.5"
45+
46+
# These crates are used for running unit tests.
47+
[dev-dependencies]
48+
wasm-bindgen-test = "0.2.45"
49+
futures = "0.1.27"
50+
js-sys = "0.3.22"
51+
wasm-bindgen-futures = "0.3.22"

0 commit comments

Comments
 (0)