You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
wasm-pack build --target web --no-default-features
10
-
```
8
+
Any Rust file you wish to modify can be found in `src/` with some tests in `tests/proj4js_tests.rs`.
9
+
In order to test your new code, you need to build it thanks to WASM. More information on how to build it can be found in [README_WASM.md](./README_WASM.md).
11
10
12
-
Or if you have installed [cargo-make](https://sagiegurari.github.io/cargo-make/), use the following
13
-
command:
11
+
### Test
14
12
15
-
```bash
16
-
cargo make wasm
17
-
```
18
-
19
-
### Running the WASM example
20
-
21
-
There is a [`index.html`] file for testing the WASM module in a navigator.
22
-
23
-
For security reasons, you need to run it from a server.
24
-
You can start a Python server with the following command:
25
-
26
-
```bash
27
-
python3 -m http.server
28
-
```
29
-
30
-
The server will automatically serve the `index.html` file in the current directory.
31
-
32
-
33
-
## Build for npm
34
-
35
-
```
36
-
cargo make wasm_bundle
37
-
```
38
-
39
-
This will create a npm bundler package in pkg-bundler
13
+
If you want to test your code, you can ron locally some demos by reading [this README](./ol-proj4rs-demo-app/README.md) in `ol-proj4rs-demo-app/`.
14
+
You can create another demo page with a HTML file + JavaScript file combo.
0 commit comments