feat: locale and fixed some debouncing stuff
This commit is contained in:
parent
75bf105e98
commit
de41ed3306
5 changed files with 89 additions and 22 deletions
23
test.html
23
test.html
|
@ -1,22 +1,27 @@
|
|||
<html x0-mods="copy,http" x0-module-root="./modules/">
|
||||
|
||||
<html
|
||||
x0-mods="locale,copy,http"
|
||||
x0-module-root="./modules/"
|
||||
x0-init="false"
|
||||
x1-locale-file="./test.json"
|
||||
x1-locale-watch
|
||||
>
|
||||
<body>
|
||||
<button onclick="window.x0.update()">Update x0</button>
|
||||
<input type="text" name="text" id="text">
|
||||
<h1 x-locale-key="main.greeting"></h1>
|
||||
<div>
|
||||
<h2>Copy</h2>
|
||||
<h2 x-locale-key="copy-section.header"></h2>
|
||||
|
||||
<div id="ex">
|
||||
<span>Original content</span>
|
||||
<span x-locale-key="copy-section.content-span"></span>
|
||||
</div>
|
||||
<div x-inner-text x-copy-query="#ex"></div>
|
||||
<div x-copy-query="#ex"></div>
|
||||
</div>
|
||||
<div>
|
||||
<h2>Get</h2>
|
||||
<h2 x-locale-key="http-section.header"></h2>
|
||||
<pre x-inner-text x-get="./test.html" x-get-refresh=5000></>
|
||||
</div>
|
||||
|
||||
<div>
|
||||
<button onclick="window.x0.update()">Update x0</button>
|
||||
</div>
|
||||
</body>
|
||||
|
||||
<script src="./x0.js"></script>
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue