mirror of
https://github.com/vlang/v.git
synced 2025-09-08 23:07:19 -04:00
examples: show how to use a v file server for the wasm version of 2048, instead of emrun
This commit is contained in:
parent
8241f22116
commit
fa8c5e369a
@ -50,6 +50,13 @@ Compile & run the game with `./v run examples/2048`
|
|||||||
```sh
|
```sh
|
||||||
emrun examples/2048/index.html
|
emrun examples/2048/index.html
|
||||||
```
|
```
|
||||||
|
|
||||||
|
If you prefer, instead of `emrun`, you can start a simple V http file server:
|
||||||
|
```sh
|
||||||
|
v -e 'import net.http.file; file.serve(folder: "examples/2048")'
|
||||||
|
```
|
||||||
|
and then open http://127.0.0.1:4001/ in your browser.
|
||||||
|
|
||||||
Once you have run the game, you can make changes,
|
Once you have opened the game in your browser, you can make changes to
|
||||||
then just recompile (step 3), and refresh the game in your browser.
|
the V source, then recompile (step 3), and refresh the browser window
|
||||||
|
with the game, to see their effect.
|
||||||
|
Loading…
x
Reference in New Issue
Block a user