Skip to content

Commit

Permalink
update to track latest rxing
Browse files Browse the repository at this point in the history
  • Loading branch information
hschimke committed Dec 20, 2024
1 parent fc2bac3 commit e358320
Show file tree
Hide file tree
Showing 5 changed files with 25 additions and 15 deletions.
11 changes: 7 additions & 4 deletions Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[package]
name = "rxing-wasm"
version = "0.3.1"
version = "0.3.2"
edition = "2021"
description = "wasm bindings for rxing to provide commong barcode operations (decode/encode)"
repository = "https://github.com/rxing-core/rxing-wasm"
Expand All @@ -17,16 +17,16 @@ decode_hints = []

[dependencies]
wasm-bindgen = "0.2.92"
js-sys = "0.3.69"
web-sys = {version = "0.3.69", features = ["CanvasRenderingContext2d", "HtmlCanvasElement", "ImageData"]}
js-sys = "0.3.76"
web-sys = {version = "0.3.76", features = ["CanvasRenderingContext2d", "HtmlCanvasElement", "ImageData"]}

# 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 isn't great for
# code size when deploying.
console_error_panic_hook = { version = "0.1.7", optional = true }

rxing = {version = "~0.6.1", default-features = false, features = ["wasm_support"]}
rxing = {version = "~0.6.3", default-features = false, features = ["wasm_support"]}
#rxing = {path="../rxing", version = "~0.2.23", default-features = false, features = ["wasm_support"]}

[dev-dependencies]
Expand All @@ -36,3 +36,6 @@ wasm-bindgen-test = "0.3.34"
# Tell `rustc` to optimize for small code size.
opt-level = "s"
lto = "fat"

[package.metadata.wasm-pack.profile.release]
wasm-opt = false
5 changes: 5 additions & 0 deletions build-wasm.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
#! /bin/sh

wasm-pack build --release
wasm-opt pkg/rxing_wasm_bg.wasm -o pkg/rxing_wasm_bg-opt.wasm --enable-bulk-memory -O1 --inlining-optimizing --heap-store-optimization --optimize-casts -O4
mv pkg/rxing_wasm_bg-opt.wasm pkg/rxing_wasm_bg.wasm
2 changes: 1 addition & 1 deletion examples/webpack+js/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -106,4 +106,4 @@ <h1>RXing - Decode Barcodes</h1>
</html>

<!-- Copyright 2023 Henry Schimke -->
<!-- Using rxing-wasm v0.3.1 -->
<!-- Using rxing-wasm v0.3.2 -->
20 changes: 11 additions & 9 deletions examples/webpack+js/package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion examples/webpack+js/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,6 @@
"node" : ">=18.0.0"
},
"dependencies": {
"rxing-wasm": "0.3.1"
"rxing-wasm": "0.3.2"
}
}

0 comments on commit e358320

Please sign in to comment.