@dashevo/wasm-dpp 2.0.1 → 2.1.0-dev.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/Cargo.toml +4 -2
- package/dist/wasm/wasm_dpp.d.ts +801 -801
- package/dist/wasm/wasm_dpp.js +37 -37
- package/dist/wasm/wasm_dpp_bg.js +1 -1
- package/lib/wasm/wasm_dpp.d.ts +801 -801
- package/package.json +2 -2
- package/scripts/build-wasm.sh +9 -1
- package/src/identity/state_transition/mod.rs +5 -5
- package/src/lib.rs +4 -4
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@dashevo/wasm-dpp",
|
|
3
|
-
"version": "2.0.
|
|
3
|
+
"version": "2.1.0-dev.3",
|
|
4
4
|
"description": "The JavaScript implementation of the Dash Platform Protocol",
|
|
5
5
|
"main": "dist/index.js",
|
|
6
6
|
"types": "dist/index.d.ts",
|
|
@@ -44,7 +44,7 @@
|
|
|
44
44
|
"@babel/core": "^7.26.10",
|
|
45
45
|
"@babel/preset-env": "^7.26.9",
|
|
46
46
|
"@dashevo/dashcore-lib": "~0.22.0",
|
|
47
|
-
"@dashevo/dpns-contract": "2.0.
|
|
47
|
+
"@dashevo/dpns-contract": "2.1.0-dev.3",
|
|
48
48
|
"@types/bs58": "^4.0.1",
|
|
49
49
|
"@types/node": "^14.6.0",
|
|
50
50
|
"@yarnpkg/pnpify": "^4.0.0-rc.42",
|
package/scripts/build-wasm.sh
CHANGED
|
@@ -49,7 +49,15 @@ fi
|
|
|
49
49
|
|
|
50
50
|
if command -v wasm-opt &> /dev/null; then
|
|
51
51
|
echo "Optimizing wasm using Binaryen"
|
|
52
|
-
|
|
52
|
+
|
|
53
|
+
# Check if we're in a release build (via CARGO_BUILD_PROFILE or GitHub event)
|
|
54
|
+
if [ "${CARGO_BUILD_PROFILE}" = "release" ] || [ "${GITHUB_EVENT_NAME:-}" = "release" ] || [ "${GITHUB_EVENT_NAME:-}" = "workflow_dispatch" ]; then
|
|
55
|
+
echo "Running full optimizations for release build (CARGO_BUILD_PROFILE=${CARGO_BUILD_PROFILE}, GITHUB_EVENT_NAME=${GITHUB_EVENT_NAME:-not_set})"
|
|
56
|
+
wasm-opt --flatten --rereloop -Oz --gufa "$OUTPUT_FILE" -o "$OUTPUT_FILE"
|
|
57
|
+
else
|
|
58
|
+
echo "Running minimal optimizations for development/PR build (CARGO_BUILD_PROFILE=${CARGO_BUILD_PROFILE}, GITHUB_EVENT_NAME=${GITHUB_EVENT_NAME:-not_set})"
|
|
59
|
+
wasm-opt -O2 "$OUTPUT_FILE" -o "$OUTPUT_FILE"
|
|
60
|
+
fi
|
|
53
61
|
else
|
|
54
62
|
echo "wasm-opt command not found. Skipping wasm optimization."
|
|
55
63
|
fi
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
pub use asset_lock_proof::*;
|
|
2
|
-
pub use identity_create_transition
|
|
3
|
-
pub use identity_credit_transfer_transition
|
|
4
|
-
pub use identity_credit_withdrawal_transition
|
|
5
|
-
pub use identity_topup_transition
|
|
6
|
-
pub use identity_update_transition
|
|
2
|
+
pub use identity_create_transition::IdentityCreateTransitionWasm;
|
|
3
|
+
pub use identity_credit_transfer_transition::IdentityCreditTransferTransitionWasm;
|
|
4
|
+
pub use identity_credit_withdrawal_transition::IdentityCreditWithdrawalTransitionWasm;
|
|
5
|
+
pub use identity_topup_transition::IdentityTopUpTransitionWasm;
|
|
6
|
+
pub use identity_update_transition::IdentityUpdateTransitionWasm;
|
|
7
7
|
// pub use validate_public_key_signatures::*;
|
|
8
8
|
|
|
9
9
|
mod asset_lock_proof;
|
package/src/lib.rs
CHANGED
|
@@ -10,13 +10,13 @@ pub use metadata::*;
|
|
|
10
10
|
// pub use state_transition::*;
|
|
11
11
|
|
|
12
12
|
mod dash_platform_protocol;
|
|
13
|
-
mod data_contract;
|
|
13
|
+
pub mod data_contract;
|
|
14
14
|
mod data_contract_factory;
|
|
15
15
|
// mod data_trigger;
|
|
16
|
-
mod document;
|
|
16
|
+
pub mod document;
|
|
17
17
|
pub mod errors;
|
|
18
|
-
mod identifier;
|
|
19
|
-
mod identity;
|
|
18
|
+
pub mod identifier;
|
|
19
|
+
pub mod identity;
|
|
20
20
|
mod metadata;
|
|
21
21
|
// mod state_repository;
|
|
22
22
|
/// State transitions
|