Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fix: spa compatible dev server + Text(En/De)coder
- Loading branch information
1 parent
6a8281b
commit 5b49844
Showing
14 changed files
with
161 additions
and
115 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,36 +1,40 @@ | ||
<!DOCTYPE html> | ||
<html lang="en"> | ||
<head> | ||
<meta charset="utf-8"> | ||
<meta name="viewport" content="width=device-width, initial-scale=1, shrink-to-fit=no"> | ||
<head> | ||
<meta charset="utf-8" /> | ||
<meta | ||
name="viewport" | ||
content="width=device-width, initial-scale=1, shrink-to-fit=no" | ||
/> | ||
|
||
<meta name="description" content=""> | ||
<meta name="description" content="" /> | ||
|
||
<link rel="icon" type="image/png" href="/public/favicon.png"> | ||
<link rel="icon" type="image/png" href="/public/favicon.png" /> | ||
|
||
<!--<link rel="stylesheet" type="text/css" href="/style.css">--> | ||
|
||
<title>Counter example</title> | ||
|
||
</head> | ||
<body> | ||
<section id="app"></section> | ||
<!-- Because of Edge, see https://github.com/samthor/fast-text-encoding --> | ||
<script type="text/javascript" src="/public/text-polyfill.min.js"></script> | ||
</head> | ||
<body> | ||
<section id="app"></section> | ||
|
||
<script src='/pkg/package.js'></script> | ||
<script src="/pkg/package.js"></script> | ||
|
||
<script> | ||
// the `wasm_bindgen` global is set to the exports of the Rust module | ||
const { render } = wasm_bindgen; | ||
// we'll defer our execution until the wasm is ready to go | ||
function run() { | ||
<script> | ||
// the `wasm_bindgen` global is set to the exports of the Rust module | ||
const { render } = wasm_bindgen; | ||
// we'll defer our execution until the wasm is ready to go | ||
function run() { | ||
render(); | ||
} | ||
// here we tell bindgen the path to the wasm file so it can run | ||
// initialization and return to us a promise when it's done | ||
wasm_bindgen('/pkg/package_bg.wasm') | ||
} | ||
// here we tell bindgen the path to the wasm file so it can run | ||
// initialization and return to us a promise when it's done | ||
wasm_bindgen("/pkg/package_bg.wasm") | ||
.then(run) | ||
.catch(console.error); | ||
</script> | ||
|
||
</body> | ||
</script> | ||
</body> | ||
</html> |
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,36 +1,40 @@ | ||
<!DOCTYPE html> | ||
<html lang="en"> | ||
<head> | ||
<meta charset="utf-8"> | ||
<meta name="viewport" content="width=device-width, initial-scale=1, shrink-to-fit=no"> | ||
<head> | ||
<meta charset="utf-8" /> | ||
<meta | ||
name="viewport" | ||
content="width=device-width, initial-scale=1, shrink-to-fit=no" | ||
/> | ||
|
||
<meta name="description" content=""> | ||
<meta name="description" content="" /> | ||
|
||
<link rel="icon" type="image/png" href="/public/favicon.png"> | ||
<link rel="icon" type="image/png" href="/public/favicon.png" /> | ||
|
||
<!--<link rel="stylesheet" type="text/css" href="/style.css">--> | ||
|
||
<title>Server interaction</title> | ||
|
||
</head> | ||
<body> | ||
<section id="main"></section> | ||
<!-- Because of Edge, see https://github.com/samthor/fast-text-encoding --> | ||
<script type="text/javascript" src="/public/text-polyfill.min.js"></script> | ||
</head> | ||
<body> | ||
<section id="main"></section> | ||
|
||
<script src='/pkg/package.js'></script> | ||
<script src="/pkg/package.js"></script> | ||
|
||
<script> | ||
// the `wasm_bindgen` global is set to the exports of the Rust module | ||
const { render } = wasm_bindgen; | ||
// we'll defer our execution until the wasm is ready to go | ||
function run() { | ||
<script> | ||
// the `wasm_bindgen` global is set to the exports of the Rust module | ||
const { render } = wasm_bindgen; | ||
// we'll defer our execution until the wasm is ready to go | ||
function run() { | ||
render(); | ||
} | ||
// here we tell bindgen the path to the wasm file so it can run | ||
// initialization and return to us a promise when it's done | ||
wasm_bindgen('/pkg/package_bg.wasm') | ||
} | ||
// here we tell bindgen the path to the wasm file so it can run | ||
// initialization and return to us a promise when it's done | ||
wasm_bindgen("/pkg/package_bg.wasm") | ||
.then(run) | ||
.catch(console.error); | ||
</script> | ||
|
||
</body> | ||
</script> | ||
</body> | ||
</html> |
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,35 +1,38 @@ | ||
<!DOCTYPE html> | ||
<html lang="en" data-framework="rust"> | ||
<head> | ||
<meta charset="utf-8"> | ||
<head> | ||
<meta charset="utf-8" /> | ||
<title>Seed • TodoMVC</title> | ||
<link rel="stylesheet" href="/index.css"> | ||
<link rel="stylesheet" href="/public/index.css" /> | ||
|
||
</head> | ||
<body> | ||
<section id="app" class="todoapp"></section> | ||
<!-- Because of Edge, see https://github.com/samthor/fast-text-encoding --> | ||
<script type="text/javascript" src="/public/text-polyfill.min.js"></script> | ||
</head> | ||
<body> | ||
<section id="app" class="todoapp"></section> | ||
|
||
<footer class="info"> | ||
<p>Double-click to edit a todo</p> | ||
<p>Created by <a href="http://github.com/David-OConnor/">David O'Connor</a></p> | ||
<p>Part of <a href="http://todomvc.com">TodoMVC</a></p> | ||
</footer> | ||
<footer class="info"> | ||
<p>Double-click to edit a todo</p> | ||
<p> | ||
Created by <a href="http://github.com/David-OConnor/">David O'Connor</a> | ||
</p> | ||
<p>Part of <a href="http://todomvc.com">TodoMVC</a></p> | ||
</footer> | ||
|
||
<script src='/pkg/package.js'></script> | ||
<script src="/pkg/package.js"></script> | ||
|
||
<script> | ||
// the `wasm_bindgen` global is set to the exports of the Rust module | ||
const { render } = wasm_bindgen; | ||
// we'll defer our execution until the wasm is ready to go | ||
function run() { | ||
<script> | ||
// the `wasm_bindgen` global is set to the exports of the Rust module | ||
const { render } = wasm_bindgen; | ||
// we'll defer our execution until the wasm is ready to go | ||
function run() { | ||
render(); | ||
} | ||
// here we tell bindgen the path to the wasm file so it can run | ||
// initialization and return to us a promise when it's done | ||
wasm_bindgen('/pkg/package_bg.wasm') | ||
} | ||
// here we tell bindgen the path to the wasm file so it can run | ||
// initialization and return to us a promise when it's done | ||
wasm_bindgen("/pkg/package_bg.wasm") | ||
.then(run) | ||
.catch(console.error); | ||
</script> | ||
|
||
</body> | ||
</script> | ||
</body> | ||
</html> |
File renamed without changes.
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,19 +1,27 @@ | ||
<!DOCTYPE html> | ||
<html> | ||
<head> | ||
<meta charset="utf-8"> | ||
<meta name="viewport" content="width=device-width, initial-scale=1, shrink-to-fit=no"> | ||
<meta charset="utf-8" /> | ||
<meta | ||
name="viewport" | ||
content="width=device-width, initial-scale=1, shrink-to-fit=no" | ||
/> | ||
<title>seed websocket example</title> | ||
|
||
<!-- Because of Edge, see https://github.com/samthor/fast-text-encoding --> | ||
<script type="text/javascript" src="/public/text-polyfill.min.js"></script> | ||
</head> | ||
<body> | ||
<section id="app"></section> | ||
<script src='/pkg/websocket.js'></script> | ||
<script src="/pkg/websocket.js"></script> | ||
<script> | ||
const { start } = wasm_bindgen; | ||
function run() { start(); } | ||
wasm_bindgen('/pkg/websocket_bg.wasm') | ||
.then(run) | ||
.catch(console.error); | ||
const { start } = wasm_bindgen; | ||
function run() { | ||
start(); | ||
} | ||
wasm_bindgen("/pkg/websocket_bg.wasm") | ||
.then(run) | ||
.catch(console.error); | ||
</script> | ||
</body> | ||
</html> |
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
Oops, something went wrong.