Skip to content

Commit

Permalink
Update README.md in WebDemo
Browse files Browse the repository at this point in the history
  • Loading branch information
notgiven688 committed Nov 15, 2023
1 parent 52c9360 commit f74118e
Showing 1 changed file with 23 additions and 11 deletions.
34 changes: 23 additions & 11 deletions other/WebDemo/README.md
Original file line number Diff line number Diff line change
@@ -1,26 +1,38 @@
## .NET WebAssembly Browser app
## Jitter2 in the browser

## Build
**Credits for this 'HowTo': https://github.com/disketteman/DotnetRaylibWasm**

You can build the app from Visual Studio or from the command-line:
## Local setup

Make sure you have the latest version of .NET 7 for example from [here](https://dotnet.microsoft.com/en-us/download/dotnet/7.0), the prototype was built with:
```
dotnet build -c Debug/Release
dotnet --version
7.0.100
```

After building the app, the result is in the `bin/$(Configuration)/net8.0/browser-wasm/AppBundle` directory.
Install the official wasm tooling:

## Run
```
dotnet workload install wasm-tools
dotnet workload install wasm-experimental
```

Install a tool to create ad-hoc http server to serve `application/wasm`:

```
dotnet tool install --global dotnet-serve
```

## Run it

You can build the app from Visual Studio or the command-line:
`publish` the solution. Don't use `build`. Publishing may take a while.

```
dotnet run -c Debug/Release
dotnet publish -C Release
```

Or you can start any static file server from the AppBundle directory:
To serve the files use this command:

```
dotnet tool install dotnet-serve
dotnet serve -d:bin/$(Configuration)/net8.0/browser-wasm/AppBundle
dotnet serve --mime .wasm=application/wasm --mime .js=text/javascript --mime .json=application/json --directory ./bin/Debug/net7.0/browser-wasm/AppBundle
```

0 comments on commit f74118e

Please sign in to comment.