Skip to content

Commit 85059be

Browse files
committed
少しブラッシュアップ
1 parent 7e18a27 commit 85059be

75 files changed

Lines changed: 1475 additions & 272 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

docs/01_00_JavaScriptを始める前に.html

Lines changed: 18 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,7 @@
3535
const path_to_root = "";
3636
const default_light_theme = "light";
3737
const default_dark_theme = "navy";
38-
window.path_to_searchindex_js = "searchindex-7160240e.js";
38+
window.path_to_searchindex_js = "searchindex-4a935368.js";
3939
</script>
4040
<!-- Start loading toc.js asap -->
4141
<script src="toc-8186ac84.js"></script>
@@ -255,7 +255,7 @@ <h2 id="ii-webページを作る3つの力htmlcssjavascriptの役割"><a class="
255255
<hr>
256256
<h2 id="iii-イベントとは"><a class="header" href="#iii-イベントとは">III. イベントとは</a></h2>
257257
<h3 id="1-きっかけを待っているコンピューター"><a class="header" href="#1-きっかけを待っているコンピューター">1. 「きっかけ」を待っているコンピューター</a></h3>
258-
<p>ふだん、Webページはただじっとしているだけに見えますが、実はあなたの操作を <strong>「今か今かと待っている」</strong> 状態です。</p>
258+
<p><ruby>普段<rt>ふだん</rt></ruby>、Webページはただじっとしているだけに見えますが、実はあなたの操作を <strong>「今か今かと待っている」</strong> 状態です。</p>
259259
<p><ruby><rt>たと</rt></ruby>えば、あなたがこんな<ruby><rt>うご</rt></ruby>きをしたとき、それがすべて「イベント」になります。</p>
260260
<ul>
261261
<li>ボタンを <strong>カチッ(クリック)</strong> としたとき。</li>
@@ -354,6 +354,22 @@ <h2 id="まとめ-1"><a class="header" href="#まとめ-1">まとめ</a></h2>
354354
<template id=fa-play><span class=fa-svg><svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 384 512"><!--! Font Awesome Free 6.2.0 by @fontawesome - https://fontawesome.com License - https://fontawesome.com/license/free (Icons: CC BY 4.0, Fonts: SIL OFL 1.1, Code: MIT License) Copyright 2022 Fonticons, Inc. --><path d="M73 39c-14.8-9.1-33.4-9.4-48.5-.9S0 62.6 0 80V432c0 17.4 9.4 33.4 24.5 41.9s33.7 8.1 48.5-.9L361 297c14.3-8.7 23-24.2 23-41s-8.7-32.2-23-41L73 39z"/></svg></span></template>
355355
<template id=fa-clock-rotate-left><span class=fa-svg><svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 512 512"><!--! Font Awesome Free 6.2.0 by @fontawesome - https://fontawesome.com License - https://fontawesome.com/license/free (Icons: CC BY 4.0, Fonts: SIL OFL 1.1, Code: MIT License) Copyright 2022 Fonticons, Inc. --><path d="M75 75L41 41C25.9 25.9 0 36.6 0 57.9V168c0 13.3 10.7 24 24 24H134.1c21.4 0 32.1-25.9 17-41l-30.8-30.8C155 85.5 203 64 256 64c106 0 192 86 192 192s-86 192-192 192c-40.8 0-78.6-12.7-109.7-34.4c-14.5-10.1-34.4-6.6-44.6 7.9s-6.6 34.4 7.9 44.6C151.2 495 201.7 512 256 512c141.4 0 256-114.6 256-256S397.4 0 256 0C185.3 0 121.3 28.7 75 75zm181 53c-13.3 0-24 10.7-24 24V256c0 6.4 2.5 12.5 7 17l72 72c9.4 9.4 24.6 9.4 33.9 0s9.4-24.6 0-33.9l-65-65V152c0-13.3-10.7-24-24-24z"/></svg></span></template>
356356

357+
<!-- Livereload script (if served using the cli tool) -->
358+
<script>
359+
const wsProtocol = location.protocol === 'https:' ? 'wss:' : 'ws:';
360+
const wsAddress = wsProtocol + "//" + location.host + "/" + "__livereload";
361+
const socket = new WebSocket(wsAddress);
362+
socket.onmessage = function (event) {
363+
if (event.data === "reload") {
364+
socket.close();
365+
location.reload();
366+
}
367+
};
368+
369+
window.onbeforeunload = function() {
370+
socket.close();
371+
}
372+
</script>
357373

358374

359375
<script>

docs/01_01_HTML.html

Lines changed: 18 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,7 @@
3535
const path_to_root = "";
3636
const default_light_theme = "light";
3737
const default_dark_theme = "navy";
38-
window.path_to_searchindex_js = "searchindex-7160240e.js";
38+
window.path_to_searchindex_js = "searchindex-4a935368.js";
3939
</script>
4040
<!-- Start loading toc.js asap -->
4141
<script src="toc-8186ac84.js"></script>
@@ -415,7 +415,7 @@ <h2 id="v-フォームユーザーからの入力にゅうりょくを受け取
415415

416416
&lt;div class="form-group"&gt;
417417
&lt;label&gt;お名前(おなまえ):&lt;/label&gt;
418-
&lt;input type="text" name="username" placeholder="&lt;ruby&gt;例&lt;rt&gt;れい&lt;/rt&gt;&lt;/ruby&gt;:Yamada Taro"&gt;
418+
&lt;input type="text" name="username" placeholder="例(れい):Yamada Taro"&gt;
419419
&lt;/div&gt;
420420

421421
&lt;div class="form-group"&gt;
@@ -501,6 +501,22 @@ <h2 id="6-まとめ"><a class="header" href="#6-まとめ">6. まとめ</a></h2>
501501
<template id=fa-play><span class=fa-svg><svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 384 512"><!--! Font Awesome Free 6.2.0 by @fontawesome - https://fontawesome.com License - https://fontawesome.com/license/free (Icons: CC BY 4.0, Fonts: SIL OFL 1.1, Code: MIT License) Copyright 2022 Fonticons, Inc. --><path d="M73 39c-14.8-9.1-33.4-9.4-48.5-.9S0 62.6 0 80V432c0 17.4 9.4 33.4 24.5 41.9s33.7 8.1 48.5-.9L361 297c14.3-8.7 23-24.2 23-41s-8.7-32.2-23-41L73 39z"/></svg></span></template>
502502
<template id=fa-clock-rotate-left><span class=fa-svg><svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 512 512"><!--! Font Awesome Free 6.2.0 by @fontawesome - https://fontawesome.com License - https://fontawesome.com/license/free (Icons: CC BY 4.0, Fonts: SIL OFL 1.1, Code: MIT License) Copyright 2022 Fonticons, Inc. --><path d="M75 75L41 41C25.9 25.9 0 36.6 0 57.9V168c0 13.3 10.7 24 24 24H134.1c21.4 0 32.1-25.9 17-41l-30.8-30.8C155 85.5 203 64 256 64c106 0 192 86 192 192s-86 192-192 192c-40.8 0-78.6-12.7-109.7-34.4c-14.5-10.1-34.4-6.6-44.6 7.9s-6.6 34.4 7.9 44.6C151.2 495 201.7 512 256 512c141.4 0 256-114.6 256-256S397.4 0 256 0C185.3 0 121.3 28.7 75 75zm181 53c-13.3 0-24 10.7-24 24V256c0 6.4 2.5 12.5 7 17l72 72c9.4 9.4 24.6 9.4 33.9 0s9.4-24.6 0-33.9l-65-65V152c0-13.3-10.7-24-24-24z"/></svg></span></template>
503503

504+
<!-- Livereload script (if served using the cli tool) -->
505+
<script>
506+
const wsProtocol = location.protocol === 'https:' ? 'wss:' : 'ws:';
507+
const wsAddress = wsProtocol + "//" + location.host + "/" + "__livereload";
508+
const socket = new WebSocket(wsAddress);
509+
socket.onmessage = function (event) {
510+
if (event.data === "reload") {
511+
socket.close();
512+
location.reload();
513+
}
514+
};
515+
516+
window.onbeforeunload = function() {
517+
socket.close();
518+
}
519+
</script>
504520

505521

506522
<script>

docs/01_02_CSS.html

Lines changed: 18 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,7 @@
3535
const path_to_root = "";
3636
const default_light_theme = "light";
3737
const default_dark_theme = "navy";
38-
window.path_to_searchindex_js = "searchindex-7160240e.js";
38+
window.path_to_searchindex_js = "searchindex-4a935368.js";
3939
</script>
4040
<!-- Start loading toc.js asap -->
4141
<script src="toc-8186ac84.js"></script>
@@ -276,7 +276,7 @@ <h2 id="iii-特定の要素クラスのスタイル"><a class="header" href="#ii
276276
<p><a href="./html/01_02_CSS_04.html">ここをクリック</a>してみましょう。</p>
277277
<hr>
278278
<h2 id="iv-特定の状態のスタイル"><a class="header" href="#iv-特定の状態のスタイル">IV. 特定の状態のスタイル</a></h2>
279-
<p>Webページには「ふだんの状態」だけでなく、「マウスが乗ったとき」のような「特別な状態」があります。この特別な状態を <strong><ruby>疑似<rt>ぎじ</rt></ruby>(ぎじ)クラス</strong> と呼びます。</p>
279+
<p>Webページには「<ruby>普段<rt>ふだん</rt></ruby>の状態」だけでなく、「マウスが乗ったとき」のような「特別な状態」があります。この特別な状態を <strong><ruby>疑似<rt>ぎじ</rt></ruby>(ぎじ)クラス</strong> と呼びます。</p>
280280
<p><strong>代表的な<ruby>疑似<rt>ぎじ</rt></ruby>クラス::hover</strong></p>
281281
<p>最もよく使われるのが :hover(ホバー)です。これは「要素の上にマウスカーソルが乗ったとき」の状態を指します。</p>
282282
<ul>
@@ -370,6 +370,22 @@ <h2 id="vi-css基礎のまとめ"><a class="header" href="#vi-css基礎のまと
370370
<template id=fa-play><span class=fa-svg><svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 384 512"><!--! Font Awesome Free 6.2.0 by @fontawesome - https://fontawesome.com License - https://fontawesome.com/license/free (Icons: CC BY 4.0, Fonts: SIL OFL 1.1, Code: MIT License) Copyright 2022 Fonticons, Inc. --><path d="M73 39c-14.8-9.1-33.4-9.4-48.5-.9S0 62.6 0 80V432c0 17.4 9.4 33.4 24.5 41.9s33.7 8.1 48.5-.9L361 297c14.3-8.7 23-24.2 23-41s-8.7-32.2-23-41L73 39z"/></svg></span></template>
371371
<template id=fa-clock-rotate-left><span class=fa-svg><svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 512 512"><!--! Font Awesome Free 6.2.0 by @fontawesome - https://fontawesome.com License - https://fontawesome.com/license/free (Icons: CC BY 4.0, Fonts: SIL OFL 1.1, Code: MIT License) Copyright 2022 Fonticons, Inc. --><path d="M75 75L41 41C25.9 25.9 0 36.6 0 57.9V168c0 13.3 10.7 24 24 24H134.1c21.4 0 32.1-25.9 17-41l-30.8-30.8C155 85.5 203 64 256 64c106 0 192 86 192 192s-86 192-192 192c-40.8 0-78.6-12.7-109.7-34.4c-14.5-10.1-34.4-6.6-44.6 7.9s-6.6 34.4 7.9 44.6C151.2 495 201.7 512 256 512c141.4 0 256-114.6 256-256S397.4 0 256 0C185.3 0 121.3 28.7 75 75zm181 53c-13.3 0-24 10.7-24 24V256c0 6.4 2.5 12.5 7 17l72 72c9.4 9.4 24.6 9.4 33.9 0s9.4-24.6 0-33.9l-65-65V152c0-13.3-10.7-24-24-24z"/></svg></span></template>
372372

373+
<!-- Livereload script (if served using the cli tool) -->
374+
<script>
375+
const wsProtocol = location.protocol === 'https:' ? 'wss:' : 'ws:';
376+
const wsAddress = wsProtocol + "//" + location.host + "/" + "__livereload";
377+
const socket = new WebSocket(wsAddress);
378+
socket.onmessage = function (event) {
379+
if (event.data === "reload") {
380+
socket.close();
381+
location.reload();
382+
}
383+
};
384+
385+
window.onbeforeunload = function() {
386+
socket.close();
387+
}
388+
</script>
373389

374390

375391
<script>

docs/02_00_はじめてのJavaScript.html

Lines changed: 17 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,7 @@
3535
const path_to_root = "";
3636
const default_light_theme = "light";
3737
const default_dark_theme = "navy";
38-
window.path_to_searchindex_js = "searchindex-7160240e.js";
38+
window.path_to_searchindex_js = "searchindex-4a935368.js";
3939
</script>
4040
<!-- Start loading toc.js asap -->
4141
<script src="toc-8186ac84.js"></script>
@@ -396,6 +396,22 @@ <h2 id="v-まとめjavascript学習のルールと習慣"><a class="header" href
396396
<template id=fa-play><span class=fa-svg><svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 384 512"><!--! Font Awesome Free 6.2.0 by @fontawesome - https://fontawesome.com License - https://fontawesome.com/license/free (Icons: CC BY 4.0, Fonts: SIL OFL 1.1, Code: MIT License) Copyright 2022 Fonticons, Inc. --><path d="M73 39c-14.8-9.1-33.4-9.4-48.5-.9S0 62.6 0 80V432c0 17.4 9.4 33.4 24.5 41.9s33.7 8.1 48.5-.9L361 297c14.3-8.7 23-24.2 23-41s-8.7-32.2-23-41L73 39z"/></svg></span></template>
397397
<template id=fa-clock-rotate-left><span class=fa-svg><svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 512 512"><!--! Font Awesome Free 6.2.0 by @fontawesome - https://fontawesome.com License - https://fontawesome.com/license/free (Icons: CC BY 4.0, Fonts: SIL OFL 1.1, Code: MIT License) Copyright 2022 Fonticons, Inc. --><path d="M75 75L41 41C25.9 25.9 0 36.6 0 57.9V168c0 13.3 10.7 24 24 24H134.1c21.4 0 32.1-25.9 17-41l-30.8-30.8C155 85.5 203 64 256 64c106 0 192 86 192 192s-86 192-192 192c-40.8 0-78.6-12.7-109.7-34.4c-14.5-10.1-34.4-6.6-44.6 7.9s-6.6 34.4 7.9 44.6C151.2 495 201.7 512 256 512c141.4 0 256-114.6 256-256S397.4 0 256 0C185.3 0 121.3 28.7 75 75zm181 53c-13.3 0-24 10.7-24 24V256c0 6.4 2.5 12.5 7 17l72 72c9.4 9.4 24.6 9.4 33.9 0s9.4-24.6 0-33.9l-65-65V152c0-13.3-10.7-24-24-24z"/></svg></span></template>
398398

399+
<!-- Livereload script (if served using the cli tool) -->
400+
<script>
401+
const wsProtocol = location.protocol === 'https:' ? 'wss:' : 'ws:';
402+
const wsAddress = wsProtocol + "//" + location.host + "/" + "__livereload";
403+
const socket = new WebSocket(wsAddress);
404+
socket.onmessage = function (event) {
405+
if (event.data === "reload") {
406+
socket.close();
407+
location.reload();
408+
}
409+
};
410+
411+
window.onbeforeunload = function() {
412+
socket.close();
413+
}
414+
</script>
399415

400416

401417
<script>

docs/02_01_変数.html

Lines changed: 17 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,7 @@
3535
const path_to_root = "";
3636
const default_light_theme = "light";
3737
const default_dark_theme = "navy";
38-
window.path_to_searchindex_js = "searchindex-7160240e.js";
38+
window.path_to_searchindex_js = "searchindex-4a935368.js";
3939
</script>
4040
<!-- Start loading toc.js asap -->
4141
<script src="toc-8186ac84.js"></script>
@@ -422,6 +422,22 @@ <h2 id="vii-まとめプログラミングの基礎を固かためる"><a class=
422422
<template id=fa-play><span class=fa-svg><svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 384 512"><!--! Font Awesome Free 6.2.0 by @fontawesome - https://fontawesome.com License - https://fontawesome.com/license/free (Icons: CC BY 4.0, Fonts: SIL OFL 1.1, Code: MIT License) Copyright 2022 Fonticons, Inc. --><path d="M73 39c-14.8-9.1-33.4-9.4-48.5-.9S0 62.6 0 80V432c0 17.4 9.4 33.4 24.5 41.9s33.7 8.1 48.5-.9L361 297c14.3-8.7 23-24.2 23-41s-8.7-32.2-23-41L73 39z"/></svg></span></template>
423423
<template id=fa-clock-rotate-left><span class=fa-svg><svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 512 512"><!--! Font Awesome Free 6.2.0 by @fontawesome - https://fontawesome.com License - https://fontawesome.com/license/free (Icons: CC BY 4.0, Fonts: SIL OFL 1.1, Code: MIT License) Copyright 2022 Fonticons, Inc. --><path d="M75 75L41 41C25.9 25.9 0 36.6 0 57.9V168c0 13.3 10.7 24 24 24H134.1c21.4 0 32.1-25.9 17-41l-30.8-30.8C155 85.5 203 64 256 64c106 0 192 86 192 192s-86 192-192 192c-40.8 0-78.6-12.7-109.7-34.4c-14.5-10.1-34.4-6.6-44.6 7.9s-6.6 34.4 7.9 44.6C151.2 495 201.7 512 256 512c141.4 0 256-114.6 256-256S397.4 0 256 0C185.3 0 121.3 28.7 75 75zm181 53c-13.3 0-24 10.7-24 24V256c0 6.4 2.5 12.5 7 17l72 72c9.4 9.4 24.6 9.4 33.9 0s9.4-24.6 0-33.9l-65-65V152c0-13.3-10.7-24-24-24z"/></svg></span></template>
424424

425+
<!-- Livereload script (if served using the cli tool) -->
426+
<script>
427+
const wsProtocol = location.protocol === 'https:' ? 'wss:' : 'ws:';
428+
const wsAddress = wsProtocol + "//" + location.host + "/" + "__livereload";
429+
const socket = new WebSocket(wsAddress);
430+
socket.onmessage = function (event) {
431+
if (event.data === "reload") {
432+
socket.close();
433+
location.reload();
434+
}
435+
};
436+
437+
window.onbeforeunload = function() {
438+
socket.close();
439+
}
440+
</script>
425441

426442

427443
<script>

docs/02_02_演算子.html

Lines changed: 17 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,7 @@
3535
const path_to_root = "";
3636
const default_light_theme = "light";
3737
const default_dark_theme = "navy";
38-
window.path_to_searchindex_js = "searchindex-7160240e.js";
38+
window.path_to_searchindex_js = "searchindex-4a935368.js";
3939
</script>
4040
<!-- Start loading toc.js asap -->
4141
<script src="toc-8186ac84.js"></script>
@@ -334,6 +334,22 @@ <h2 id="vi-まとめプログラミングの基礎を固かためる"><a class="
334334
<template id=fa-play><span class=fa-svg><svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 384 512"><!--! Font Awesome Free 6.2.0 by @fontawesome - https://fontawesome.com License - https://fontawesome.com/license/free (Icons: CC BY 4.0, Fonts: SIL OFL 1.1, Code: MIT License) Copyright 2022 Fonticons, Inc. --><path d="M73 39c-14.8-9.1-33.4-9.4-48.5-.9S0 62.6 0 80V432c0 17.4 9.4 33.4 24.5 41.9s33.7 8.1 48.5-.9L361 297c14.3-8.7 23-24.2 23-41s-8.7-32.2-23-41L73 39z"/></svg></span></template>
335335
<template id=fa-clock-rotate-left><span class=fa-svg><svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 512 512"><!--! Font Awesome Free 6.2.0 by @fontawesome - https://fontawesome.com License - https://fontawesome.com/license/free (Icons: CC BY 4.0, Fonts: SIL OFL 1.1, Code: MIT License) Copyright 2022 Fonticons, Inc. --><path d="M75 75L41 41C25.9 25.9 0 36.6 0 57.9V168c0 13.3 10.7 24 24 24H134.1c21.4 0 32.1-25.9 17-41l-30.8-30.8C155 85.5 203 64 256 64c106 0 192 86 192 192s-86 192-192 192c-40.8 0-78.6-12.7-109.7-34.4c-14.5-10.1-34.4-6.6-44.6 7.9s-6.6 34.4 7.9 44.6C151.2 495 201.7 512 256 512c141.4 0 256-114.6 256-256S397.4 0 256 0C185.3 0 121.3 28.7 75 75zm181 53c-13.3 0-24 10.7-24 24V256c0 6.4 2.5 12.5 7 17l72 72c9.4 9.4 24.6 9.4 33.9 0s9.4-24.6 0-33.9l-65-65V152c0-13.3-10.7-24-24-24z"/></svg></span></template>
336336

337+
<!-- Livereload script (if served using the cli tool) -->
338+
<script>
339+
const wsProtocol = location.protocol === 'https:' ? 'wss:' : 'ws:';
340+
const wsAddress = wsProtocol + "//" + location.host + "/" + "__livereload";
341+
const socket = new WebSocket(wsAddress);
342+
socket.onmessage = function (event) {
343+
if (event.data === "reload") {
344+
socket.close();
345+
location.reload();
346+
}
347+
};
348+
349+
window.onbeforeunload = function() {
350+
socket.close();
351+
}
352+
</script>
337353

338354

339355
<script>

docs/02_03_制御文.html

Lines changed: 17 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,7 @@
3535
const path_to_root = "";
3636
const default_light_theme = "light";
3737
const default_dark_theme = "navy";
38-
window.path_to_searchindex_js = "searchindex-7160240e.js";
38+
window.path_to_searchindex_js = "searchindex-4a935368.js";
3939
</script>
4040
<!-- Start loading toc.js asap -->
4141
<script src="toc-8186ac84.js"></script>
@@ -386,6 +386,22 @@ <h2 id="viii-まとめと学習のアドバイス"><a class="header" href="#viii
386386
<template id=fa-play><span class=fa-svg><svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 384 512"><!--! Font Awesome Free 6.2.0 by @fontawesome - https://fontawesome.com License - https://fontawesome.com/license/free (Icons: CC BY 4.0, Fonts: SIL OFL 1.1, Code: MIT License) Copyright 2022 Fonticons, Inc. --><path d="M73 39c-14.8-9.1-33.4-9.4-48.5-.9S0 62.6 0 80V432c0 17.4 9.4 33.4 24.5 41.9s33.7 8.1 48.5-.9L361 297c14.3-8.7 23-24.2 23-41s-8.7-32.2-23-41L73 39z"/></svg></span></template>
387387
<template id=fa-clock-rotate-left><span class=fa-svg><svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 512 512"><!--! Font Awesome Free 6.2.0 by @fontawesome - https://fontawesome.com License - https://fontawesome.com/license/free (Icons: CC BY 4.0, Fonts: SIL OFL 1.1, Code: MIT License) Copyright 2022 Fonticons, Inc. --><path d="M75 75L41 41C25.9 25.9 0 36.6 0 57.9V168c0 13.3 10.7 24 24 24H134.1c21.4 0 32.1-25.9 17-41l-30.8-30.8C155 85.5 203 64 256 64c106 0 192 86 192 192s-86 192-192 192c-40.8 0-78.6-12.7-109.7-34.4c-14.5-10.1-34.4-6.6-44.6 7.9s-6.6 34.4 7.9 44.6C151.2 495 201.7 512 256 512c141.4 0 256-114.6 256-256S397.4 0 256 0C185.3 0 121.3 28.7 75 75zm181 53c-13.3 0-24 10.7-24 24V256c0 6.4 2.5 12.5 7 17l72 72c9.4 9.4 24.6 9.4 33.9 0s9.4-24.6 0-33.9l-65-65V152c0-13.3-10.7-24-24-24z"/></svg></span></template>
388388

389+
<!-- Livereload script (if served using the cli tool) -->
390+
<script>
391+
const wsProtocol = location.protocol === 'https:' ? 'wss:' : 'ws:';
392+
const wsAddress = wsProtocol + "//" + location.host + "/" + "__livereload";
393+
const socket = new WebSocket(wsAddress);
394+
socket.onmessage = function (event) {
395+
if (event.data === "reload") {
396+
socket.close();
397+
location.reload();
398+
}
399+
};
400+
401+
window.onbeforeunload = function() {
402+
socket.close();
403+
}
404+
</script>
389405

390406

391407
<script>

0 commit comments

Comments
 (0)