added docs
This commit is contained in:
1 parent
1dcb884552
commit
8acba51d27
17 files changed
+2212
-5
No files matched your search
@@ -0,0 +1,208 @@
|
|||||||
|
<!DOCTYPE html>
|
||||||
|
<html>
|
||||||
|
<head>
|
||||||
|
<title>HockeyGame - https://example.com/foo/ba documentation</title>
|
||||||
|
<meta charset="utf-8">
|
||||||
|
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
||||||
|
<meta name="doc-current-symbol" content="HockeyGame">
|
||||||
|
<link rel="stylesheet" href="./styles.css">
|
||||||
|
</head>
|
||||||
|
<body>
|
||||||
|
|
||||||
|
|
||||||
|
<nav id="sidepanel">
|
||||||
|
<h2><a href="index.html"><span>https://example.com/foo/ba</span></a></h2>
|
||||||
|
|
||||||
|
<div class="section_title"><div class="symbol_kind kind_Class_text kind_Class_bg" title="Class">
|
||||||
|
c
|
||||||
|
</div>
|
||||||
|
<h3 class="kind_Class_text">Classes</h3></div>
|
||||||
|
<ul>
|
||||||
|
|
||||||
|
<li>
|
||||||
|
<a href="HockeyGame.html" title="HockeyGame" class=""><span><code>HockeyGame</code></span></a>
|
||||||
|
</li>
|
||||||
|
|
||||||
|
</ul>
|
||||||
|
|
||||||
|
<div class="section_title"><div class="symbol_kind kind_Function_text kind_Function_bg" title="Function">
|
||||||
|
f
|
||||||
|
</div>
|
||||||
|
<h3 class="kind_Function_text">Functions</h3></div>
|
||||||
|
<ul>
|
||||||
|
|
||||||
|
<li>
|
||||||
|
<a href="average.html" title="average" class=""><span><code>average</code></span></a>
|
||||||
|
</li>
|
||||||
|
|
||||||
|
<li>
|
||||||
|
<a href="isValidIsbn.html" title="isValidIsbn" class=""><span><code>isValidIsbn</code></span></a>
|
||||||
|
</li>
|
||||||
|
|
||||||
|
<li>
|
||||||
|
<a href="isValidIsbn10.html" title="isValidIsbn10" class=""><span><code>isValidIsbn10</code></span></a>
|
||||||
|
</li>
|
||||||
|
|
||||||
|
<li>
|
||||||
|
<a href="isValidIsbn13.html" title="isValidIsbn13" class=""><span><code>isValidIsbn13</code></span></a>
|
||||||
|
</li>
|
||||||
|
|
||||||
|
<li>
|
||||||
|
<a href="std.html" title="std" class=""><span><code>std</code></span></a>
|
||||||
|
</li>
|
||||||
|
|
||||||
|
</ul>
|
||||||
|
|
||||||
|
<div class="section_title"><div class="symbol_kind kind_Variable_text kind_Variable_bg" title="Variable">
|
||||||
|
v
|
||||||
|
</div>
|
||||||
|
<h3 class="kind_Variable_text">Variables</h3></div>
|
||||||
|
<ul>
|
||||||
|
|
||||||
|
<li>
|
||||||
|
<a href="INFINITY.html" title="INFINITY" class=""><span><code>INFINITY</code></span></a>
|
||||||
|
</li>
|
||||||
|
|
||||||
|
</ul>
|
||||||
|
|
||||||
|
</nav>
|
||||||
|
|
||||||
|
|
||||||
|
<div id="content">
|
||||||
|
<a href="./index.html">← Back to index</a>
|
||||||
|
<input type="text" id="searchbar" style="display: none;" />
|
||||||
|
|
||||||
|
<main class="symbol_group" id="symbol_HockeyGame">
|
||||||
|
|
||||||
|
<article class="symbol">
|
||||||
|
<div class="symbol_header">
|
||||||
|
<div class="doc_block_title">
|
||||||
|
<div>
|
||||||
|
<span class="kind_Class_text">class</span> <span style="font-weight: 700;">HockeyGame</span>
|
||||||
|
</div>
|
||||||
|
<div class="doc_block_subtitle">
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<div>
|
||||||
|
<div class="doc_block_items"><div>
|
||||||
|
Constructors
|
||||||
|
<div class="section">
|
||||||
|
<div class="doc_item" id="constructor_0">
|
||||||
|
|
||||||
|
<a
|
||||||
|
href="#constructor_0"
|
||||||
|
class="anchor"
|
||||||
|
aria-label="Anchor"
|
||||||
|
tabIndex=-1
|
||||||
|
>
|
||||||
|
<div style="width: 14px; height: 14px; display: inline-block;">🔗</div>
|
||||||
|
</a>
|
||||||
|
|
||||||
|
<div class="doc_entry">
|
||||||
|
<span class="doc_entry_children">
|
||||||
|
<code>
|
||||||
|
<span style="font-weight: 700;">HockeyGame</span><span style="font-weight: 500;">
|
||||||
|
()
|
||||||
|
</span>
|
||||||
|
</code>
|
||||||
|
</span>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div><div>
|
||||||
|
Methods
|
||||||
|
<div class="section">
|
||||||
|
<div class="doc_item" id="method_awayTeamScores_0">
|
||||||
|
|
||||||
|
<a
|
||||||
|
href="#method_awayTeamScores_0"
|
||||||
|
class="anchor"
|
||||||
|
aria-label="Anchor"
|
||||||
|
tabIndex=-1
|
||||||
|
>
|
||||||
|
<div style="width: 14px; height: 14px; display: inline-block;">🔗</div>
|
||||||
|
</a>
|
||||||
|
|
||||||
|
<div class="doc_entry">
|
||||||
|
<span class="doc_entry_children">
|
||||||
|
<code>
|
||||||
|
<span style="font-weight: 700;">awayTeamScores</span><span style="font-weight: 500;">
|
||||||
|
(): <span>void</span>
|
||||||
|
</span>
|
||||||
|
</code>
|
||||||
|
</span>
|
||||||
|
</div>
|
||||||
|
<div class="markdown"><p>Call this method when away team scores. It will
|
||||||
|
increase home team score by 1 point.</p>
|
||||||
|
</div>
|
||||||
|
</div><div class="doc_item" id="method_homeTeamScores_0">
|
||||||
|
|
||||||
|
<a
|
||||||
|
href="#method_homeTeamScores_0"
|
||||||
|
class="anchor"
|
||||||
|
aria-label="Anchor"
|
||||||
|
tabIndex=-1
|
||||||
|
>
|
||||||
|
<div style="width: 14px; height: 14px; display: inline-block;">🔗</div>
|
||||||
|
</a>
|
||||||
|
|
||||||
|
<div class="doc_entry">
|
||||||
|
<span class="doc_entry_children">
|
||||||
|
<code>
|
||||||
|
<span style="font-weight: 700;">homeTeamScores</span><span style="font-weight: 500;">
|
||||||
|
(): <span>void</span>
|
||||||
|
</span>
|
||||||
|
</code>
|
||||||
|
</span>
|
||||||
|
</div>
|
||||||
|
<div class="markdown"><p>Call this method when home team scores. It will
|
||||||
|
increase home team score by 1 point.</p>
|
||||||
|
</div>
|
||||||
|
</div><div class="doc_item" id="method_winner_0">
|
||||||
|
|
||||||
|
<a
|
||||||
|
href="#method_winner_0"
|
||||||
|
class="anchor"
|
||||||
|
aria-label="Anchor"
|
||||||
|
tabIndex=-1
|
||||||
|
>
|
||||||
|
<div style="width: 14px; height: 14px; display: inline-block;">🔗</div>
|
||||||
|
</a>
|
||||||
|
|
||||||
|
<div class="doc_entry">
|
||||||
|
<span class="doc_entry_children">
|
||||||
|
<code>
|
||||||
|
<span style="font-weight: 700;">winner</span><span style="font-weight: 500;">
|
||||||
|
()
|
||||||
|
</span>
|
||||||
|
</code>
|
||||||
|
</span>
|
||||||
|
</div>
|
||||||
|
<div class="markdown"><p>Returns winner of the game.</p>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div></div>
|
||||||
|
</div>
|
||||||
|
</article>
|
||||||
|
|
||||||
|
</main>
|
||||||
|
|
||||||
|
|
||||||
|
<div id="searchResults"></div>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
</body>
|
||||||
|
<script src="./search_index.js" defer></script>
|
||||||
|
<script src="./fuse.js" defer></script>
|
||||||
|
<script src="./search.js" defer></script>
|
||||||
|
</html>
|
||||||
@@ -0,0 +1,128 @@
|
|||||||
|
<!DOCTYPE html>
|
||||||
|
<html>
|
||||||
|
<head>
|
||||||
|
<title>INFINITY - https://example.com/foo/ba documentation</title>
|
||||||
|
<meta charset="utf-8">
|
||||||
|
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
||||||
|
<meta name="doc-current-symbol" content="INFINITY">
|
||||||
|
<link rel="stylesheet" href="./styles.css">
|
||||||
|
</head>
|
||||||
|
<body>
|
||||||
|
|
||||||
|
|
||||||
|
<nav id="sidepanel">
|
||||||
|
<h2><a href="index.html"><span>https://example.com/foo/ba</span></a></h2>
|
||||||
|
|
||||||
|
<div class="section_title"><div class="symbol_kind kind_Class_text kind_Class_bg" title="Class">
|
||||||
|
c
|
||||||
|
</div>
|
||||||
|
<h3 class="kind_Class_text">Classes</h3></div>
|
||||||
|
<ul>
|
||||||
|
|
||||||
|
<li>
|
||||||
|
<a href="HockeyGame.html" title="HockeyGame" class=""><span><code>HockeyGame</code></span></a>
|
||||||
|
</li>
|
||||||
|
|
||||||
|
</ul>
|
||||||
|
|
||||||
|
<div class="section_title"><div class="symbol_kind kind_Function_text kind_Function_bg" title="Function">
|
||||||
|
f
|
||||||
|
</div>
|
||||||
|
<h3 class="kind_Function_text">Functions</h3></div>
|
||||||
|
<ul>
|
||||||
|
|
||||||
|
<li>
|
||||||
|
<a href="average.html" title="average" class=""><span><code>average</code></span></a>
|
||||||
|
</li>
|
||||||
|
|
||||||
|
<li>
|
||||||
|
<a href="isValidIsbn.html" title="isValidIsbn" class=""><span><code>isValidIsbn</code></span></a>
|
||||||
|
</li>
|
||||||
|
|
||||||
|
<li>
|
||||||
|
<a href="isValidIsbn10.html" title="isValidIsbn10" class=""><span><code>isValidIsbn10</code></span></a>
|
||||||
|
</li>
|
||||||
|
|
||||||
|
<li>
|
||||||
|
<a href="isValidIsbn13.html" title="isValidIsbn13" class=""><span><code>isValidIsbn13</code></span></a>
|
||||||
|
</li>
|
||||||
|
|
||||||
|
<li>
|
||||||
|
<a href="std.html" title="std" class=""><span><code>std</code></span></a>
|
||||||
|
</li>
|
||||||
|
|
||||||
|
</ul>
|
||||||
|
|
||||||
|
<div class="section_title"><div class="symbol_kind kind_Variable_text kind_Variable_bg" title="Variable">
|
||||||
|
v
|
||||||
|
</div>
|
||||||
|
<h3 class="kind_Variable_text">Variables</h3></div>
|
||||||
|
<ul>
|
||||||
|
|
||||||
|
<li>
|
||||||
|
<a href="INFINITY.html" title="INFINITY" class=""><span><code>INFINITY</code></span></a>
|
||||||
|
</li>
|
||||||
|
|
||||||
|
</ul>
|
||||||
|
|
||||||
|
</nav>
|
||||||
|
|
||||||
|
|
||||||
|
<div id="content">
|
||||||
|
<a href="./index.html">← Back to index</a>
|
||||||
|
<input type="text" id="searchbar" style="display: none;" />
|
||||||
|
|
||||||
|
<main class="symbol_group" id="symbol_INFINITY">
|
||||||
|
|
||||||
|
<article class="symbol">
|
||||||
|
<div class="symbol_header">
|
||||||
|
<div class="doc_block_title">
|
||||||
|
<div>
|
||||||
|
<span class="kind_Variable_text">variable</span> <span style="font-weight: 700;">INFINITY</span>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<div>
|
||||||
|
<div class="doc_block_items"><div class="markdown_summary"><p>In statistics, infinity is set to 30.</p>
|
||||||
|
</div><div>
|
||||||
|
type
|
||||||
|
<div class="section">
|
||||||
|
<div class="doc_item" id="variable_INFINITY">
|
||||||
|
|
||||||
|
<a
|
||||||
|
href="#variable_INFINITY"
|
||||||
|
class="anchor"
|
||||||
|
aria-label="Anchor"
|
||||||
|
tabIndex=-1
|
||||||
|
>
|
||||||
|
<div style="width: 14px; height: 14px; display: inline-block;">🔗</div>
|
||||||
|
</a>
|
||||||
|
|
||||||
|
<div class="doc_entry">
|
||||||
|
<span class="doc_entry_children">
|
||||||
|
<code>
|
||||||
|
<span style="font-weight: 700;"></span><span style="font-weight: 500;">
|
||||||
|
<span>30</span>
|
||||||
|
</span>
|
||||||
|
</code>
|
||||||
|
</span>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div></div>
|
||||||
|
</div>
|
||||||
|
</article>
|
||||||
|
|
||||||
|
</main>
|
||||||
|
|
||||||
|
|
||||||
|
<div id="searchResults"></div>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
</body>
|
||||||
|
<script src="./search_index.js" defer></script>
|
||||||
|
<script src="./fuse.js" defer></script>
|
||||||
|
<script src="./search.js" defer></script>
|
||||||
|
</html>
|
||||||
@@ -0,0 +1,167 @@
|
|||||||
|
<!DOCTYPE html>
|
||||||
|
<html>
|
||||||
|
<head>
|
||||||
|
<title>average - https://example.com/foo/ba documentation</title>
|
||||||
|
<meta charset="utf-8">
|
||||||
|
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
||||||
|
<meta name="doc-current-symbol" content="average">
|
||||||
|
<link rel="stylesheet" href="./styles.css">
|
||||||
|
</head>
|
||||||
|
<body>
|
||||||
|
|
||||||
|
|
||||||
|
<nav id="sidepanel">
|
||||||
|
<h2><a href="index.html"><span>https://example.com/foo/ba</span></a></h2>
|
||||||
|
|
||||||
|
<div class="section_title"><div class="symbol_kind kind_Class_text kind_Class_bg" title="Class">
|
||||||
|
c
|
||||||
|
</div>
|
||||||
|
<h3 class="kind_Class_text">Classes</h3></div>
|
||||||
|
<ul>
|
||||||
|
|
||||||
|
<li>
|
||||||
|
<a href="HockeyGame.html" title="HockeyGame" class=""><span><code>HockeyGame</code></span></a>
|
||||||
|
</li>
|
||||||
|
|
||||||
|
</ul>
|
||||||
|
|
||||||
|
<div class="section_title"><div class="symbol_kind kind_Function_text kind_Function_bg" title="Function">
|
||||||
|
f
|
||||||
|
</div>
|
||||||
|
<h3 class="kind_Function_text">Functions</h3></div>
|
||||||
|
<ul>
|
||||||
|
|
||||||
|
<li>
|
||||||
|
<a href="average.html" title="average" class=""><span><code>average</code></span></a>
|
||||||
|
</li>
|
||||||
|
|
||||||
|
<li>
|
||||||
|
<a href="isValidIsbn.html" title="isValidIsbn" class=""><span><code>isValidIsbn</code></span></a>
|
||||||
|
</li>
|
||||||
|
|
||||||
|
<li>
|
||||||
|
<a href="isValidIsbn10.html" title="isValidIsbn10" class=""><span><code>isValidIsbn10</code></span></a>
|
||||||
|
</li>
|
||||||
|
|
||||||
|
<li>
|
||||||
|
<a href="isValidIsbn13.html" title="isValidIsbn13" class=""><span><code>isValidIsbn13</code></span></a>
|
||||||
|
</li>
|
||||||
|
|
||||||
|
<li>
|
||||||
|
<a href="std.html" title="std" class=""><span><code>std</code></span></a>
|
||||||
|
</li>
|
||||||
|
|
||||||
|
</ul>
|
||||||
|
|
||||||
|
<div class="section_title"><div class="symbol_kind kind_Variable_text kind_Variable_bg" title="Variable">
|
||||||
|
v
|
||||||
|
</div>
|
||||||
|
<h3 class="kind_Variable_text">Variables</h3></div>
|
||||||
|
<ul>
|
||||||
|
|
||||||
|
<li>
|
||||||
|
<a href="INFINITY.html" title="INFINITY" class=""><span><code>INFINITY</code></span></a>
|
||||||
|
</li>
|
||||||
|
|
||||||
|
</ul>
|
||||||
|
|
||||||
|
</nav>
|
||||||
|
|
||||||
|
|
||||||
|
<div id="content">
|
||||||
|
<a href="./index.html">← Back to index</a>
|
||||||
|
<input type="text" id="searchbar" style="display: none;" />
|
||||||
|
|
||||||
|
<main class="symbol_group" id="symbol_average">
|
||||||
|
|
||||||
|
<article class="symbol">
|
||||||
|
<div class="symbol_header">
|
||||||
|
<div class="doc_block_title">
|
||||||
|
<div>
|
||||||
|
<span class="kind_Function_text">function</span> <span style="font-weight: 700;">average</span>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<div>
|
||||||
|
|
||||||
|
<style scoped>
|
||||||
|
|
||||||
|
#function_average_0 {
|
||||||
|
display: none;
|
||||||
|
}
|
||||||
|
#function_average_0:checked ~ *:last-child > :not(#function_average_0_div) {
|
||||||
|
display: none;
|
||||||
|
}
|
||||||
|
#function_average_0:checked ~ div:first-of-type > label[for='function_average_0'] {
|
||||||
|
background-color: #056CF00C;
|
||||||
|
border: solid 2px rgb(37 99 235);
|
||||||
|
cursor: unset;
|
||||||
|
}
|
||||||
|
#function_average_0:checked ~ div:first-of-type > label[for='function_average_0'] > code {
|
||||||
|
margin: -1px;
|
||||||
|
}
|
||||||
|
|
||||||
|
</style>
|
||||||
|
<input type="radio" name="function_average" id="function_average_0" checked />
|
||||||
|
|
||||||
|
<div class="function_overload_selectors">
|
||||||
|
|
||||||
|
<label for="function_average_0" class="function_overload_label">
|
||||||
|
<code>
|
||||||
|
<span style="font-weight: 700;">average</span><span style="font-weight: 500;">(<span><span>lst</span></span>)</span>
|
||||||
|
</code>
|
||||||
|
|
||||||
|
</label>
|
||||||
|
|
||||||
|
</div>
|
||||||
|
<div>
|
||||||
|
<div class="doc_block_items" id="function_average_0_div"><div class="markdown_summary"><p>Computes the average of the list. If the list is empty, the
|
||||||
|
function returns NaN</p>
|
||||||
|
</div><div>
|
||||||
|
Parameters
|
||||||
|
<div class="section">
|
||||||
|
<div class="doc_item" id="function_average_0_parameters_lst">
|
||||||
|
|
||||||
|
<a
|
||||||
|
href="#function_average_0_parameters_lst"
|
||||||
|
class="anchor"
|
||||||
|
aria-label="Anchor"
|
||||||
|
tabIndex=-1
|
||||||
|
>
|
||||||
|
<div style="width: 14px; height: 14px; display: inline-block;">🔗</div>
|
||||||
|
</a>
|
||||||
|
|
||||||
|
<div class="doc_entry">
|
||||||
|
<span class="doc_entry_children">
|
||||||
|
<code>
|
||||||
|
<span style="font-weight: 700;">lst</span><span style="font-weight: 500;">
|
||||||
|
|
||||||
|
</span>
|
||||||
|
</code>
|
||||||
|
</span>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div><div>
|
||||||
|
Return Type
|
||||||
|
<div class="section">
|
||||||
|
|
||||||
|
</div>
|
||||||
|
</div></div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</article>
|
||||||
|
|
||||||
|
</main>
|
||||||
|
|
||||||
|
|
||||||
|
<div id="searchResults"></div>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
</body>
|
||||||
|
<script src="./search_index.js" defer></script>
|
||||||
|
<script src="./fuse.js" defer></script>
|
||||||
|
<script src="./search.js" defer></script>
|
||||||
|
</html>
|
||||||
@@ -0,0 +1,90 @@
|
|||||||
|
<!DOCTYPE html>
|
||||||
|
<html>
|
||||||
|
<head>
|
||||||
|
<title>Index - https://example.com/foo/ba documentation</title>
|
||||||
|
<meta charset="utf-8">
|
||||||
|
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
||||||
|
<meta name="doc-current-symbol" content="">
|
||||||
|
<link rel="stylesheet" href="./styles.css">
|
||||||
|
</head>
|
||||||
|
<body>
|
||||||
|
|
||||||
|
|
||||||
|
<div id="sidepanel">
|
||||||
|
<h2><a href="./">https://example.com/foo/ba</a></h2>
|
||||||
|
<h3>APIs</h3>
|
||||||
|
<ul>
|
||||||
|
|
||||||
|
<li>
|
||||||
|
<a href="./#Classs">Class</a>
|
||||||
|
</li>
|
||||||
|
|
||||||
|
<li>
|
||||||
|
<a href="./#Functions">Function</a>
|
||||||
|
</li>
|
||||||
|
|
||||||
|
<li>
|
||||||
|
<a href="./#Variables">Variable</a>
|
||||||
|
</li>
|
||||||
|
|
||||||
|
</ul>
|
||||||
|
|
||||||
|
<h3>Modules</h3>
|
||||||
|
<ul>
|
||||||
|
|
||||||
|
<li>
|
||||||
|
<a href="./">books.js</a>
|
||||||
|
</li>
|
||||||
|
|
||||||
|
<li>
|
||||||
|
<a href="./">hockey.js</a>
|
||||||
|
</li>
|
||||||
|
|
||||||
|
<li>
|
||||||
|
<a href="./">stats.js</a>
|
||||||
|
</li>
|
||||||
|
|
||||||
|
</ul>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<div id="content">
|
||||||
|
<h2>Index</h2>
|
||||||
|
|
||||||
|
<input type="text" id="searchbar" style="display: none;" />
|
||||||
|
|
||||||
|
<main>
|
||||||
|
|
||||||
|
|
||||||
|
<section>
|
||||||
|
<h2>Module<pre>books.js</pre></h2>
|
||||||
|
<div class="markdown"></div>
|
||||||
|
</section>
|
||||||
|
|
||||||
|
<hr>
|
||||||
|
|
||||||
|
|
||||||
|
<section>
|
||||||
|
<h2>Module<pre>hockey.js</pre></h2>
|
||||||
|
<div class="markdown"></div>
|
||||||
|
</section>
|
||||||
|
|
||||||
|
<hr>
|
||||||
|
|
||||||
|
|
||||||
|
<section>
|
||||||
|
<h2>Module<pre>stats.js</pre></h2>
|
||||||
|
<div class="markdown"></div>
|
||||||
|
</section>
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
</main>
|
||||||
|
|
||||||
|
<div id="searchResults"></div>
|
||||||
|
<div>
|
||||||
|
|
||||||
|
</body>
|
||||||
|
<script src="./search_index.js" defer></script>
|
||||||
|
<script src="./fuse.js" defer></script>
|
||||||
|
<script src="./search.js" defer></script>
|
||||||
|
</html>
|
||||||
@@ -0,0 +1,11 @@
|
|||||||
|
// deno-fmt-ignore-file
|
||||||
|
// deno-lint-ignore-file
|
||||||
|
/**
|
||||||
|
* Fuse.js v7.0.0 - Lightweight fuzzy-search (http://fusejs.io)
|
||||||
|
*
|
||||||
|
* Copyright (c) 2023 Kiro Risk (http://kiro.me)
|
||||||
|
* All Rights Reserved. Apache Software License 2.0
|
||||||
|
*
|
||||||
|
* http://www.apache.org/licenses/LICENSE-2.0
|
||||||
|
*/
|
||||||
|
var e,t;e=this,t=function(){"use strict";function e(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function t(t){for(var n=1;n<arguments.length;n++){var r=null!=arguments[n]?arguments[n]:{};n%2?e(Object(r),!0).forEach((function(e){c(t,e,r[e])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(r)):e(Object(r)).forEach((function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(r,e))}))}return t}function n(e){return n="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},n(e)}function r(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function i(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,v(r.key),r)}}function o(e,t,n){return t&&i(e.prototype,t),n&&i(e,n),Object.defineProperty(e,"prototype",{writable:!1}),e}function c(e,t,n){return(t=v(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function a(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&u(e,t)}function s(e){return s=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(e){return e.__proto__||Object.getPrototypeOf(e)},s(e)}function u(e,t){return u=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(e,t){return e.__proto__=t,e},u(e,t)}function h(e,t){if(t&&("object"==typeof t||"function"==typeof t))return t;if(void 0!==t)throw new TypeError("Derived constructors may only return object or undefined");return function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e)}function l(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=s(e);if(t){var i=s(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return h(this,n)}}function f(e){return function(e){if(Array.isArray(e))return d(e)}(e)||function(e){if("undefined"!=typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(e)||function(e,t){if(e){if("string"==typeof e)return d(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?d(e,t):void 0}}(e)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function d(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function v(e){var t=function(e,t){if("object"!=typeof e||null===e)return e;var n=e[Symbol.toPrimitive];if(void 0!==n){var r=n.call(e,t||"default");if("object"!=typeof r)return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)}(e,"string");return"symbol"==typeof t?t:String(t)}function g(e){return Array.isArray?Array.isArray(e):"[object Array]"===S(e)}var y=1/0;function p(e){return null==e?"":function(e){if("string"==typeof e)return e;var t=e+"";return"0"==t&&1/e==-y?"-0":t}(e)}function m(e){return"string"==typeof e}function k(e){return"number"==typeof e}function M(e){return!0===e||!1===e||function(e){return b(e)&&null!==e}(e)&&"[object Boolean]"==S(e)}function b(e){return"object"===n(e)}function x(e){return null!=e}function w(e){return!e.trim().length}function S(e){return null==e?void 0===e?"[object Undefined]":"[object Null]":Object.prototype.toString.call(e)}var L=function(e){return"Missing ".concat(e," property in key")},_=function(e){return"Property 'weight' in key '".concat(e,"' must be a positive integer")},O=Object.prototype.hasOwnProperty,j=function(){function e(t){var n=this;r(this,e),this._keys=[],this._keyMap={};var i=0;t.forEach((function(e){var t=A(e);n._keys.push(t),n._keyMap[t.id]=t,i+=t.weight})),this._keys.forEach((function(e){e.weight/=i}))}return o(e,[{key:"get",value:function(e){return this._keyMap[e]}},{key:"keys",value:function(){return this._keys}},{key:"toJSON",value:function(){return JSON.stringify(this._keys)}}]),e}();function A(e){var t=null,n=null,r=null,i=1,o=null;if(m(e)||g(e))r=e,t=I(e),n=C(e);else{if(!O.call(e,"name"))throw new ErLine truncated
|
||||||
+218
@@ -0,0 +1,218 @@
|
|||||||
|
<!DOCTYPE html>
|
||||||
|
<html>
|
||||||
|
<head>
|
||||||
|
<title>Index - https://example.com/foo/ba documentation</title>
|
||||||
|
<meta charset="utf-8">
|
||||||
|
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
||||||
|
<meta name="doc-current-symbol" content="">
|
||||||
|
<link rel="stylesheet" href="./styles.css">
|
||||||
|
</head>
|
||||||
|
<body>
|
||||||
|
|
||||||
|
|
||||||
|
<nav id="sidepanel">
|
||||||
|
<h2><a href="./index.html"><span>https://example.com/foo/ba</span></a></h2>
|
||||||
|
|
||||||
|
<div class="section_title"><div class="symbol_kind kind_Class_text kind_Class_bg" title="Class">
|
||||||
|
c
|
||||||
|
</div>
|
||||||
|
<h3 class="kind_Class_text">Classes</h3></div>
|
||||||
|
<ul>
|
||||||
|
|
||||||
|
<li>
|
||||||
|
<a href="./HockeyGame.html" title="HockeyGame" class=""><span><code>HockeyGame</code></span></a>
|
||||||
|
</li>
|
||||||
|
|
||||||
|
</ul>
|
||||||
|
|
||||||
|
<div class="section_title"><div class="symbol_kind kind_Function_text kind_Function_bg" title="Function">
|
||||||
|
f
|
||||||
|
</div>
|
||||||
|
<h3 class="kind_Function_text">Functions</h3></div>
|
||||||
|
<ul>
|
||||||
|
|
||||||
|
<li>
|
||||||
|
<a href="./average.html" title="average" class=""><span><code>average</code></span></a>
|
||||||
|
</li>
|
||||||
|
|
||||||
|
<li>
|
||||||
|
<a href="./isValidIsbn.html" title="isValidIsbn" class=""><span><code>isValidIsbn</code></span></a>
|
||||||
|
</li>
|
||||||
|
|
||||||
|
<li>
|
||||||
|
<a href="./isValidIsbn10.html" title="isValidIsbn10" class=""><span><code>isValidIsbn10</code></span></a>
|
||||||
|
</li>
|
||||||
|
|
||||||
|
<li>
|
||||||
|
<a href="./isValidIsbn13.html" title="isValidIsbn13" class=""><span><code>isValidIsbn13</code></span></a>
|
||||||
|
</li>
|
||||||
|
|
||||||
|
<li>
|
||||||
|
<a href="./std.html" title="std" class=""><span><code>std</code></span></a>
|
||||||
|
</li>
|
||||||
|
|
||||||
|
</ul>
|
||||||
|
|
||||||
|
<div class="section_title"><div class="symbol_kind kind_Variable_text kind_Variable_bg" title="Variable">
|
||||||
|
v
|
||||||
|
</div>
|
||||||
|
<h3 class="kind_Variable_text">Variables</h3></div>
|
||||||
|
<ul>
|
||||||
|
|
||||||
|
<li>
|
||||||
|
<a href="./INFINITY.html" title="INFINITY" class=""><span><code>INFINITY</code></span></a>
|
||||||
|
</li>
|
||||||
|
|
||||||
|
</ul>
|
||||||
|
|
||||||
|
</nav>
|
||||||
|
|
||||||
|
|
||||||
|
<div id="content">
|
||||||
|
<h2>Index</h2>
|
||||||
|
|
||||||
|
<input type="text" id="searchbar" style="display: none;" />
|
||||||
|
|
||||||
|
<main>
|
||||||
|
|
||||||
|
<div>
|
||||||
|
<h2 class="section_title" id="Classes"><a href="#Classes" aria-label="Anchor">Classes</a></h2>
|
||||||
|
<table class="symbol_section">
|
||||||
|
|
||||||
|
<tr>
|
||||||
|
<td class="symbol_section_symbol">
|
||||||
|
<div>
|
||||||
|
<div class="symbol_kind kind_Class_text kind_Class_bg" title="Class">
|
||||||
|
c
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<a href="./HockeyGame.html">HockeyGame</a>
|
||||||
|
</div>
|
||||||
|
</td>
|
||||||
|
<td class="symbol_section_doc">
|
||||||
|
|
||||||
|
</td>
|
||||||
|
</tr>
|
||||||
|
|
||||||
|
</table>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<div>
|
||||||
|
<h2 class="section_title" id="Functions"><a href="#Functions" aria-label="Anchor">Functions</a></h2>
|
||||||
|
<table class="symbol_section">
|
||||||
|
|
||||||
|
<tr>
|
||||||
|
<td class="symbol_section_symbol">
|
||||||
|
<div>
|
||||||
|
<div class="symbol_kind kind_Function_text kind_Function_bg" title="Function">
|
||||||
|
f
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<a href="./average.html">average</a>
|
||||||
|
</div>
|
||||||
|
</td>
|
||||||
|
<td class="symbol_section_doc">
|
||||||
|
<div class="markdown_summary"><p>Computes the average of the list. If the list is empty, the
|
||||||
|
function returns NaN</p>
|
||||||
|
</div>
|
||||||
|
</td>
|
||||||
|
</tr>
|
||||||
|
|
||||||
|
<tr>
|
||||||
|
<td class="symbol_section_symbol">
|
||||||
|
<div>
|
||||||
|
<div class="symbol_kind kind_Function_text kind_Function_bg" title="Function">
|
||||||
|
f
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<a href="./isValidIsbn.html">isValidIsbn</a>
|
||||||
|
</div>
|
||||||
|
</td>
|
||||||
|
<td class="symbol_section_doc">
|
||||||
|
|
||||||
|
</td>
|
||||||
|
</tr>
|
||||||
|
|
||||||
|
<tr>
|
||||||
|
<td class="symbol_section_symbol">
|
||||||
|
<div>
|
||||||
|
<div class="symbol_kind kind_Function_text kind_Function_bg" title="Function">
|
||||||
|
f
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<a href="./isValidIsbn10.html">isValidIsbn10</a>
|
||||||
|
</div>
|
||||||
|
</td>
|
||||||
|
<td class="symbol_section_doc">
|
||||||
|
|
||||||
|
</td>
|
||||||
|
</tr>
|
||||||
|
|
||||||
|
<tr>
|
||||||
|
<td class="symbol_section_symbol">
|
||||||
|
<div>
|
||||||
|
<div class="symbol_kind kind_Function_text kind_Function_bg" title="Function">
|
||||||
|
f
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<a href="./isValidIsbn13.html">isValidIsbn13</a>
|
||||||
|
</div>
|
||||||
|
</td>
|
||||||
|
<td class="symbol_section_doc">
|
||||||
|
|
||||||
|
</td>
|
||||||
|
</tr>
|
||||||
|
|
||||||
|
<tr>
|
||||||
|
<td class="symbol_section_symbol">
|
||||||
|
<div>
|
||||||
|
<div class="symbol_kind kind_Function_text kind_Function_bg" title="Function">
|
||||||
|
f
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<a href="./std.html">std</a>
|
||||||
|
</div>
|
||||||
|
</td>
|
||||||
|
<td class="symbol_section_doc">
|
||||||
|
<div class="markdown_summary"><p>Computes the standard deviation of the list. If the list is empty, the
|
||||||
|
function returns NaN</p>
|
||||||
|
</div>
|
||||||
|
</td>
|
||||||
|
</tr>
|
||||||
|
|
||||||
|
</table>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<div>
|
||||||
|
<h2 class="section_title" id="Variables"><a href="#Variables" aria-label="Anchor">Variables</a></h2>
|
||||||
|
<table class="symbol_section">
|
||||||
|
|
||||||
|
<tr>
|
||||||
|
<td class="symbol_section_symbol">
|
||||||
|
<div>
|
||||||
|
<div class="symbol_kind kind_Variable_text kind_Variable_bg" title="Variable">
|
||||||
|
v
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<a href="./INFINITY.html">INFINITY</a>
|
||||||
|
</div>
|
||||||
|
</td>
|
||||||
|
<td class="symbol_section_doc">
|
||||||
|
<div class="markdown_summary"><p>In statistics, infinity is set to 30.</p>
|
||||||
|
</div>
|
||||||
|
</td>
|
||||||
|
</tr>
|
||||||
|
|
||||||
|
</table>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
</main>
|
||||||
|
|
||||||
|
<div id="searchResults"></div>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
</body>
|
||||||
|
<script src="./search_index.js" defer></script>
|
||||||
|
<script src="./fuse.js" defer></script>
|
||||||
|
<script src="./search.js" defer></script>
|
||||||
|
</html>
|
||||||
@@ -0,0 +1,165 @@
|
|||||||
|
<!DOCTYPE html>
|
||||||
|
<html>
|
||||||
|
<head>
|
||||||
|
<title>isValidIsbn - https://example.com/foo/ba documentation</title>
|
||||||
|
<meta charset="utf-8">
|
||||||
|
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
||||||
|
<meta name="doc-current-symbol" content="isValidIsbn">
|
||||||
|
<link rel="stylesheet" href="./styles.css">
|
||||||
|
</head>
|
||||||
|
<body>
|
||||||
|
|
||||||
|
|
||||||
|
<nav id="sidepanel">
|
||||||
|
<h2><a href="index.html"><span>https://example.com/foo/ba</span></a></h2>
|
||||||
|
|
||||||
|
<div class="section_title"><div class="symbol_kind kind_Class_text kind_Class_bg" title="Class">
|
||||||
|
c
|
||||||
|
</div>
|
||||||
|
<h3 class="kind_Class_text">Classes</h3></div>
|
||||||
|
<ul>
|
||||||
|
|
||||||
|
<li>
|
||||||
|
<a href="HockeyGame.html" title="HockeyGame" class=""><span><code>HockeyGame</code></span></a>
|
||||||
|
</li>
|
||||||
|
|
||||||
|
</ul>
|
||||||
|
|
||||||
|
<div class="section_title"><div class="symbol_kind kind_Function_text kind_Function_bg" title="Function">
|
||||||
|
f
|
||||||
|
</div>
|
||||||
|
<h3 class="kind_Function_text">Functions</h3></div>
|
||||||
|
<ul>
|
||||||
|
|
||||||
|
<li>
|
||||||
|
<a href="average.html" title="average" class=""><span><code>average</code></span></a>
|
||||||
|
</li>
|
||||||
|
|
||||||
|
<li>
|
||||||
|
<a href="isValidIsbn.html" title="isValidIsbn" class=""><span><code>isValidIsbn</code></span></a>
|
||||||
|
</li>
|
||||||
|
|
||||||
|
<li>
|
||||||
|
<a href="isValidIsbn10.html" title="isValidIsbn10" class=""><span><code>isValidIsbn10</code></span></a>
|
||||||
|
</li>
|
||||||
|
|
||||||
|
<li>
|
||||||
|
<a href="isValidIsbn13.html" title="isValidIsbn13" class=""><span><code>isValidIsbn13</code></span></a>
|
||||||
|
</li>
|
||||||
|
|
||||||
|
<li>
|
||||||
|
<a href="std.html" title="std" class=""><span><code>std</code></span></a>
|
||||||
|
</li>
|
||||||
|
|
||||||
|
</ul>
|
||||||
|
|
||||||
|
<div class="section_title"><div class="symbol_kind kind_Variable_text kind_Variable_bg" title="Variable">
|
||||||
|
v
|
||||||
|
</div>
|
||||||
|
<h3 class="kind_Variable_text">Variables</h3></div>
|
||||||
|
<ul>
|
||||||
|
|
||||||
|
<li>
|
||||||
|
<a href="INFINITY.html" title="INFINITY" class=""><span><code>INFINITY</code></span></a>
|
||||||
|
</li>
|
||||||
|
|
||||||
|
</ul>
|
||||||
|
|
||||||
|
</nav>
|
||||||
|
|
||||||
|
|
||||||
|
<div id="content">
|
||||||
|
<a href="./index.html">← Back to index</a>
|
||||||
|
<input type="text" id="searchbar" style="display: none;" />
|
||||||
|
|
||||||
|
<main class="symbol_group" id="symbol_isValidIsbn">
|
||||||
|
|
||||||
|
<article class="symbol">
|
||||||
|
<div class="symbol_header">
|
||||||
|
<div class="doc_block_title">
|
||||||
|
<div>
|
||||||
|
<span class="kind_Function_text">function</span> <span style="font-weight: 700;">isValidIsbn</span>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<div>
|
||||||
|
|
||||||
|
<style scoped>
|
||||||
|
|
||||||
|
#function_isValidIsbn_0 {
|
||||||
|
display: none;
|
||||||
|
}
|
||||||
|
#function_isValidIsbn_0:checked ~ *:last-child > :not(#function_isValidIsbn_0_div) {
|
||||||
|
display: none;
|
||||||
|
}
|
||||||
|
#function_isValidIsbn_0:checked ~ div:first-of-type > label[for='function_isValidIsbn_0'] {
|
||||||
|
background-color: #056CF00C;
|
||||||
|
border: solid 2px rgb(37 99 235);
|
||||||
|
cursor: unset;
|
||||||
|
}
|
||||||
|
#function_isValidIsbn_0:checked ~ div:first-of-type > label[for='function_isValidIsbn_0'] > code {
|
||||||
|
margin: -1px;
|
||||||
|
}
|
||||||
|
|
||||||
|
</style>
|
||||||
|
<input type="radio" name="function_isValidIsbn" id="function_isValidIsbn_0" checked />
|
||||||
|
|
||||||
|
<div class="function_overload_selectors">
|
||||||
|
|
||||||
|
<label for="function_isValidIsbn_0" class="function_overload_label">
|
||||||
|
<code>
|
||||||
|
<span style="font-weight: 700;">isValidIsbn</span><span style="font-weight: 500;">(<span><span>str</span></span>)</span>
|
||||||
|
</code>
|
||||||
|
|
||||||
|
</label>
|
||||||
|
|
||||||
|
</div>
|
||||||
|
<div>
|
||||||
|
<div class="doc_block_items" id="function_isValidIsbn_0_div"><div>
|
||||||
|
Parameters
|
||||||
|
<div class="section">
|
||||||
|
<div class="doc_item" id="function_isValidIsbn_0_parameters_str">
|
||||||
|
|
||||||
|
<a
|
||||||
|
href="#function_isValidIsbn_0_parameters_str"
|
||||||
|
class="anchor"
|
||||||
|
aria-label="Anchor"
|
||||||
|
tabIndex=-1
|
||||||
|
>
|
||||||
|
<div style="width: 14px; height: 14px; display: inline-block;">🔗</div>
|
||||||
|
</a>
|
||||||
|
|
||||||
|
<div class="doc_entry">
|
||||||
|
<span class="doc_entry_children">
|
||||||
|
<code>
|
||||||
|
<span style="font-weight: 700;">str</span><span style="font-weight: 500;">
|
||||||
|
|
||||||
|
</span>
|
||||||
|
</code>
|
||||||
|
</span>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div><div>
|
||||||
|
Return Type
|
||||||
|
<div class="section">
|
||||||
|
|
||||||
|
</div>
|
||||||
|
</div></div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</article>
|
||||||
|
|
||||||
|
</main>
|
||||||
|
|
||||||
|
|
||||||
|
<div id="searchResults"></div>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
</body>
|
||||||
|
<script src="./search_index.js" defer></script>
|
||||||
|
<script src="./fuse.js" defer></script>
|
||||||
|
<script src="./search.js" defer></script>
|
||||||
|
</html>
|
||||||
@@ -0,0 +1,165 @@
|
|||||||
|
<!DOCTYPE html>
|
||||||
|
<html>
|
||||||
|
<head>
|
||||||
|
<title>isValidIsbn10 - https://example.com/foo/ba documentation</title>
|
||||||
|
<meta charset="utf-8">
|
||||||
|
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
||||||
|
<meta name="doc-current-symbol" content="isValidIsbn10">
|
||||||
|
<link rel="stylesheet" href="./styles.css">
|
||||||
|
</head>
|
||||||
|
<body>
|
||||||
|
|
||||||
|
|
||||||
|
<nav id="sidepanel">
|
||||||
|
<h2><a href="index.html"><span>https://example.com/foo/ba</span></a></h2>
|
||||||
|
|
||||||
|
<div class="section_title"><div class="symbol_kind kind_Class_text kind_Class_bg" title="Class">
|
||||||
|
c
|
||||||
|
</div>
|
||||||
|
<h3 class="kind_Class_text">Classes</h3></div>
|
||||||
|
<ul>
|
||||||
|
|
||||||
|
<li>
|
||||||
|
<a href="HockeyGame.html" title="HockeyGame" class=""><span><code>HockeyGame</code></span></a>
|
||||||
|
</li>
|
||||||
|
|
||||||
|
</ul>
|
||||||
|
|
||||||
|
<div class="section_title"><div class="symbol_kind kind_Function_text kind_Function_bg" title="Function">
|
||||||
|
f
|
||||||
|
</div>
|
||||||
|
<h3 class="kind_Function_text">Functions</h3></div>
|
||||||
|
<ul>
|
||||||
|
|
||||||
|
<li>
|
||||||
|
<a href="average.html" title="average" class=""><span><code>average</code></span></a>
|
||||||
|
</li>
|
||||||
|
|
||||||
|
<li>
|
||||||
|
<a href="isValidIsbn.html" title="isValidIsbn" class=""><span><code>isValidIsbn</code></span></a>
|
||||||
|
</li>
|
||||||
|
|
||||||
|
<li>
|
||||||
|
<a href="isValidIsbn10.html" title="isValidIsbn10" class=""><span><code>isValidIsbn10</code></span></a>
|
||||||
|
</li>
|
||||||
|
|
||||||
|
<li>
|
||||||
|
<a href="isValidIsbn13.html" title="isValidIsbn13" class=""><span><code>isValidIsbn13</code></span></a>
|
||||||
|
</li>
|
||||||
|
|
||||||
|
<li>
|
||||||
|
<a href="std.html" title="std" class=""><span><code>std</code></span></a>
|
||||||
|
</li>
|
||||||
|
|
||||||
|
</ul>
|
||||||
|
|
||||||
|
<div class="section_title"><div class="symbol_kind kind_Variable_text kind_Variable_bg" title="Variable">
|
||||||
|
v
|
||||||
|
</div>
|
||||||
|
<h3 class="kind_Variable_text">Variables</h3></div>
|
||||||
|
<ul>
|
||||||
|
|
||||||
|
<li>
|
||||||
|
<a href="INFINITY.html" title="INFINITY" class=""><span><code>INFINITY</code></span></a>
|
||||||
|
</li>
|
||||||
|
|
||||||
|
</ul>
|
||||||
|
|
||||||
|
</nav>
|
||||||
|
|
||||||
|
|
||||||
|
<div id="content">
|
||||||
|
<a href="./index.html">← Back to index</a>
|
||||||
|
<input type="text" id="searchbar" style="display: none;" />
|
||||||
|
|
||||||
|
<main class="symbol_group" id="symbol_isValidIsbn10">
|
||||||
|
|
||||||
|
<article class="symbol">
|
||||||
|
<div class="symbol_header">
|
||||||
|
<div class="doc_block_title">
|
||||||
|
<div>
|
||||||
|
<span class="kind_Function_text">function</span> <span style="font-weight: 700;">isValidIsbn10</span>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<div>
|
||||||
|
|
||||||
|
<style scoped>
|
||||||
|
|
||||||
|
#function_isValidIsbn10_0 {
|
||||||
|
display: none;
|
||||||
|
}
|
||||||
|
#function_isValidIsbn10_0:checked ~ *:last-child > :not(#function_isValidIsbn10_0_div) {
|
||||||
|
display: none;
|
||||||
|
}
|
||||||
|
#function_isValidIsbn10_0:checked ~ div:first-of-type > label[for='function_isValidIsbn10_0'] {
|
||||||
|
background-color: #056CF00C;
|
||||||
|
border: solid 2px rgb(37 99 235);
|
||||||
|
cursor: unset;
|
||||||
|
}
|
||||||
|
#function_isValidIsbn10_0:checked ~ div:first-of-type > label[for='function_isValidIsbn10_0'] > code {
|
||||||
|
margin: -1px;
|
||||||
|
}
|
||||||
|
|
||||||
|
</style>
|
||||||
|
<input type="radio" name="function_isValidIsbn10" id="function_isValidIsbn10_0" checked />
|
||||||
|
|
||||||
|
<div class="function_overload_selectors">
|
||||||
|
|
||||||
|
<label for="function_isValidIsbn10_0" class="function_overload_label">
|
||||||
|
<code>
|
||||||
|
<span style="font-weight: 700;">isValidIsbn10</span><span style="font-weight: 500;">(<span><span>str</span></span>)</span>
|
||||||
|
</code>
|
||||||
|
|
||||||
|
</label>
|
||||||
|
|
||||||
|
</div>
|
||||||
|
<div>
|
||||||
|
<div class="doc_block_items" id="function_isValidIsbn10_0_div"><div>
|
||||||
|
Parameters
|
||||||
|
<div class="section">
|
||||||
|
<div class="doc_item" id="function_isValidIsbn10_0_parameters_str">
|
||||||
|
|
||||||
|
<a
|
||||||
|
href="#function_isValidIsbn10_0_parameters_str"
|
||||||
|
class="anchor"
|
||||||
|
aria-label="Anchor"
|
||||||
|
tabIndex=-1
|
||||||
|
>
|
||||||
|
<div style="width: 14px; height: 14px; display: inline-block;">🔗</div>
|
||||||
|
</a>
|
||||||
|
|
||||||
|
<div class="doc_entry">
|
||||||
|
<span class="doc_entry_children">
|
||||||
|
<code>
|
||||||
|
<span style="font-weight: 700;">str</span><span style="font-weight: 500;">
|
||||||
|
|
||||||
|
</span>
|
||||||
|
</code>
|
||||||
|
</span>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div><div>
|
||||||
|
Return Type
|
||||||
|
<div class="section">
|
||||||
|
|
||||||
|
</div>
|
||||||
|
</div></div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</article>
|
||||||
|
|
||||||
|
</main>
|
||||||
|
|
||||||
|
|
||||||
|
<div id="searchResults"></div>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
</body>
|
||||||
|
<script src="./search_index.js" defer></script>
|
||||||
|
<script src="./fuse.js" defer></script>
|
||||||
|
<script src="./search.js" defer></script>
|
||||||
|
</html>
|
||||||
@@ -0,0 +1,165 @@
|
|||||||
|
<!DOCTYPE html>
|
||||||
|
<html>
|
||||||
|
<head>
|
||||||
|
<title>isValidIsbn13 - https://example.com/foo/ba documentation</title>
|
||||||
|
<meta charset="utf-8">
|
||||||
|
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
||||||
|
<meta name="doc-current-symbol" content="isValidIsbn13">
|
||||||
|
<link rel="stylesheet" href="./styles.css">
|
||||||
|
</head>
|
||||||
|
<body>
|
||||||
|
|
||||||
|
|
||||||
|
<nav id="sidepanel">
|
||||||
|
<h2><a href="index.html"><span>https://example.com/foo/ba</span></a></h2>
|
||||||
|
|
||||||
|
<div class="section_title"><div class="symbol_kind kind_Class_text kind_Class_bg" title="Class">
|
||||||
|
c
|
||||||
|
</div>
|
||||||
|
<h3 class="kind_Class_text">Classes</h3></div>
|
||||||
|
<ul>
|
||||||
|
|
||||||
|
<li>
|
||||||
|
<a href="HockeyGame.html" title="HockeyGame" class=""><span><code>HockeyGame</code></span></a>
|
||||||
|
</li>
|
||||||
|
|
||||||
|
</ul>
|
||||||
|
|
||||||
|
<div class="section_title"><div class="symbol_kind kind_Function_text kind_Function_bg" title="Function">
|
||||||
|
f
|
||||||
|
</div>
|
||||||
|
<h3 class="kind_Function_text">Functions</h3></div>
|
||||||
|
<ul>
|
||||||
|
|
||||||
|
<li>
|
||||||
|
<a href="average.html" title="average" class=""><span><code>average</code></span></a>
|
||||||
|
</li>
|
||||||
|
|
||||||
|
<li>
|
||||||
|
<a href="isValidIsbn.html" title="isValidIsbn" class=""><span><code>isValidIsbn</code></span></a>
|
||||||
|
</li>
|
||||||
|
|
||||||
|
<li>
|
||||||
|
<a href="isValidIsbn10.html" title="isValidIsbn10" class=""><span><code>isValidIsbn10</code></span></a>
|
||||||
|
</li>
|
||||||
|
|
||||||
|
<li>
|
||||||
|
<a href="isValidIsbn13.html" title="isValidIsbn13" class=""><span><code>isValidIsbn13</code></span></a>
|
||||||
|
</li>
|
||||||
|
|
||||||
|
<li>
|
||||||
|
<a href="std.html" title="std" class=""><span><code>std</code></span></a>
|
||||||
|
</li>
|
||||||
|
|
||||||
|
</ul>
|
||||||
|
|
||||||
|
<div class="section_title"><div class="symbol_kind kind_Variable_text kind_Variable_bg" title="Variable">
|
||||||
|
v
|
||||||
|
</div>
|
||||||
|
<h3 class="kind_Variable_text">Variables</h3></div>
|
||||||
|
<ul>
|
||||||
|
|
||||||
|
<li>
|
||||||
|
<a href="INFINITY.html" title="INFINITY" class=""><span><code>INFINITY</code></span></a>
|
||||||
|
</li>
|
||||||
|
|
||||||
|
</ul>
|
||||||
|
|
||||||
|
</nav>
|
||||||
|
|
||||||
|
|
||||||
|
<div id="content">
|
||||||
|
<a href="./index.html">← Back to index</a>
|
||||||
|
<input type="text" id="searchbar" style="display: none;" />
|
||||||
|
|
||||||
|
<main class="symbol_group" id="symbol_isValidIsbn13">
|
||||||
|
|
||||||
|
<article class="symbol">
|
||||||
|
<div class="symbol_header">
|
||||||
|
<div class="doc_block_title">
|
||||||
|
<div>
|
||||||
|
<span class="kind_Function_text">function</span> <span style="font-weight: 700;">isValidIsbn13</span>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<div>
|
||||||
|
|
||||||
|
<style scoped>
|
||||||
|
|
||||||
|
#function_isValidIsbn13_0 {
|
||||||
|
display: none;
|
||||||
|
}
|
||||||
|
#function_isValidIsbn13_0:checked ~ *:last-child > :not(#function_isValidIsbn13_0_div) {
|
||||||
|
display: none;
|
||||||
|
}
|
||||||
|
#function_isValidIsbn13_0:checked ~ div:first-of-type > label[for='function_isValidIsbn13_0'] {
|
||||||
|
background-color: #056CF00C;
|
||||||
|
border: solid 2px rgb(37 99 235);
|
||||||
|
cursor: unset;
|
||||||
|
}
|
||||||
|
#function_isValidIsbn13_0:checked ~ div:first-of-type > label[for='function_isValidIsbn13_0'] > code {
|
||||||
|
margin: -1px;
|
||||||
|
}
|
||||||
|
|
||||||
|
</style>
|
||||||
|
<input type="radio" name="function_isValidIsbn13" id="function_isValidIsbn13_0" checked />
|
||||||
|
|
||||||
|
<div class="function_overload_selectors">
|
||||||
|
|
||||||
|
<label for="function_isValidIsbn13_0" class="function_overload_label">
|
||||||
|
<code>
|
||||||
|
<span style="font-weight: 700;">isValidIsbn13</span><span style="font-weight: 500;">(<span><span>str</span></span>)</span>
|
||||||
|
</code>
|
||||||
|
|
||||||
|
</label>
|
||||||
|
|
||||||
|
</div>
|
||||||
|
<div>
|
||||||
|
<div class="doc_block_items" id="function_isValidIsbn13_0_div"><div>
|
||||||
|
Parameters
|
||||||
|
<div class="section">
|
||||||
|
<div class="doc_item" id="function_isValidIsbn13_0_parameters_str">
|
||||||
|
|
||||||
|
<a
|
||||||
|
href="#function_isValidIsbn13_0_parameters_str"
|
||||||
|
class="anchor"
|
||||||
|
aria-label="Anchor"
|
||||||
|
tabIndex=-1
|
||||||
|
>
|
||||||
|
<div style="width: 14px; height: 14px; display: inline-block;">🔗</div>
|
||||||
|
</a>
|
||||||
|
|
||||||
|
<div class="doc_entry">
|
||||||
|
<span class="doc_entry_children">
|
||||||
|
<code>
|
||||||
|
<span style="font-weight: 700;">str</span><span style="font-weight: 500;">
|
||||||
|
|
||||||
|
</span>
|
||||||
|
</code>
|
||||||
|
</span>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div><div>
|
||||||
|
Return Type
|
||||||
|
<div class="section">
|
||||||
|
|
||||||
|
</div>
|
||||||
|
</div></div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</article>
|
||||||
|
|
||||||
|
</main>
|
||||||
|
|
||||||
|
|
||||||
|
<div id="searchResults"></div>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
</body>
|
||||||
|
<script src="./search_index.js" defer></script>
|
||||||
|
<script src="./fuse.js" defer></script>
|
||||||
|
<script src="./search.js" defer></script>
|
||||||
|
</html>
|
||||||
+169
@@ -0,0 +1,169 @@
|
|||||||
|
const Fuse = window.Fuse;
|
||||||
|
|
||||||
|
const searchInput = document.querySelector("#searchbar");
|
||||||
|
const mainContentTags = document.getElementsByTagName("main");
|
||||||
|
const searchResultsDiv = document.querySelector("#searchResults");
|
||||||
|
const currentSymbol =
|
||||||
|
document.querySelector("meta[name='doc-current-symbol']").attributes
|
||||||
|
.getNamedItem("content").value;
|
||||||
|
const pathToRoot = currentSymbol.split(".").slice(1).map(() => "../").join("");
|
||||||
|
searchInput.removeAttribute("style");
|
||||||
|
|
||||||
|
const SEARCH_INDEX = window.DENO_DOC_SEARCH_INDEX;
|
||||||
|
|
||||||
|
const fuse = new Fuse(SEARCH_INDEX.nodes, {
|
||||||
|
keys: [{
|
||||||
|
name: "name",
|
||||||
|
weight: 2,
|
||||||
|
}, {
|
||||||
|
name: "nsQualifiers",
|
||||||
|
weight: 1,
|
||||||
|
}],
|
||||||
|
isCaseSensitive: false,
|
||||||
|
minMatchCharLength: 2,
|
||||||
|
threshold: 0.4,
|
||||||
|
});
|
||||||
|
|
||||||
|
const loadedUrl = new URL(window.location.href);
|
||||||
|
const val = loadedUrl.searchParams.get("q");
|
||||||
|
if (val) {
|
||||||
|
searchInput.value = val;
|
||||||
|
doSearch(val);
|
||||||
|
}
|
||||||
|
|
||||||
|
window.addEventListener("load", function () {
|
||||||
|
document.addEventListener("keydown", function (event) {
|
||||||
|
if (event.key.toLowerCase() === "s") {
|
||||||
|
if (event.target !== searchInput) {
|
||||||
|
searchInput.focus();
|
||||||
|
event.preventDefault();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
});
|
||||||
|
|
||||||
|
const emptyPlaceholder = "Click or press 'S' to search...";
|
||||||
|
searchInput.placeholder = emptyPlaceholder;
|
||||||
|
|
||||||
|
searchInput.addEventListener("focus", function () {
|
||||||
|
searchInput.placeholder = "Type your query here...";
|
||||||
|
});
|
||||||
|
|
||||||
|
searchInput.addEventListener("blur", function () {
|
||||||
|
searchInput.placeholder = emptyPlaceholder;
|
||||||
|
});
|
||||||
|
});
|
||||||
|
|
||||||
|
function debounce(func, delay) {
|
||||||
|
let timerId;
|
||||||
|
|
||||||
|
return function () {
|
||||||
|
const context = this;
|
||||||
|
const args = arguments;
|
||||||
|
|
||||||
|
clearTimeout(timerId);
|
||||||
|
|
||||||
|
timerId = setTimeout(function () {
|
||||||
|
func.apply(context, args);
|
||||||
|
}, delay);
|
||||||
|
};
|
||||||
|
}
|
||||||
|
|
||||||
|
const debouncedSearch = debounce(doSearch, 250);
|
||||||
|
|
||||||
|
searchInput.addEventListener("input", (e) => {
|
||||||
|
const val = e.target.value;
|
||||||
|
debouncedSearch(val);
|
||||||
|
});
|
||||||
|
|
||||||
|
function doSearch(val) {
|
||||||
|
if (!val) {
|
||||||
|
updateCurrentLocation(val);
|
||||||
|
showPage();
|
||||||
|
} else {
|
||||||
|
const results = searchInIndex(val);
|
||||||
|
// console.log("results", results);
|
||||||
|
updateCurrentLocation(val);
|
||||||
|
renderResults(results);
|
||||||
|
showSearchResults();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
function updateCurrentLocation(val) {
|
||||||
|
const url = new URL(window.location.href);
|
||||||
|
if (val) {
|
||||||
|
url.searchParams.set("q", val);
|
||||||
|
} else {
|
||||||
|
url.searchParams.delete("q");
|
||||||
|
}
|
||||||
|
window.history.replaceState({}, "", url.href);
|
||||||
|
}
|
||||||
|
|
||||||
|
function showPage() {
|
||||||
|
for (const mainTag of mainContentTags) {
|
||||||
|
mainTag.style.display = "block";
|
||||||
|
}
|
||||||
|
searchResultsDiv.style.display = "none";
|
||||||
|
}
|
||||||
|
|
||||||
|
function showSearchResults() {
|
||||||
|
for (const mainTag of mainContentTags) {
|
||||||
|
mainTag.style.display = "none";
|
||||||
|
}
|
||||||
|
searchResultsDiv.style.display = "block";
|
||||||
|
}
|
||||||
|
|
||||||
|
function renderResults(results) {
|
||||||
|
if (results.length === 0) {
|
||||||
|
searchResultsDiv.innerHTML = `<span>No result</span>`;
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
|
let html = `<ul>`;
|
||||||
|
|
||||||
|
for (const result of results) {
|
||||||
|
// console.log("result", result);
|
||||||
|
const [rustKind, title, symbol] = docNodeKindToStringVariants(result.kind);
|
||||||
|
const label = result.nsQualifiers
|
||||||
|
? `${result.nsQualifiers}.${result.name}`
|
||||||
|
: result.name;
|
||||||
|
html += `<li>
|
||||||
|
<a href="${pathToRoot}${label.split(".").join("/")}.html">
|
||||||
|
<div>
|
||||||
|
<div class="symbol_kind kind_${rustKind}_text kind_${rustKind}_bg" title="${title}">
|
||||||
|
${symbol}
|
||||||
|
</div>
|
||||||
|
<span>${label}</span>
|
||||||
|
</div>
|
||||||
|
<div>${result.location.filename}:${result.location.line}</div>
|
||||||
|
</a>
|
||||||
|
</li>`;
|
||||||
|
}
|
||||||
|
|
||||||
|
html += `</ul>`;
|
||||||
|
searchResultsDiv.innerHTML = html;
|
||||||
|
}
|
||||||
|
|
||||||
|
function searchInIndex(val) {
|
||||||
|
return fuse.search(val).map((result) => result.item);
|
||||||
|
}
|
||||||
|
|
||||||
|
function docNodeKindToStringVariants(kind) {
|
||||||
|
switch (kind) {
|
||||||
|
case "function":
|
||||||
|
return ["Function", "Function", "f"];
|
||||||
|
case "variable":
|
||||||
|
return ["Variable", "Variable", "v"];
|
||||||
|
case "class":
|
||||||
|
return ["Class", "Class", "c"];
|
||||||
|
case "enum":
|
||||||
|
return ["Enum", "Enum", "E"];
|
||||||
|
case "interface":
|
||||||
|
return ["Interface", "Interface", "I"];
|
||||||
|
case "typeAlias":
|
||||||
|
return ["TypeAlias", "Type Alias", "T"];
|
||||||
|
case "namespace":
|
||||||
|
return ["Namespace", "Namespace", "N"];
|
||||||
|
default:
|
||||||
|
return [];
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -0,0 +1,3 @@
|
|||||||
|
(function () {
|
||||||
|
window.DENO_DOC_SEARCH_INDEX = {"nodes":[{"kind":"function","name":"isValidIsbn13","nsQualifiers":"","location":{"filename":"books.js","line":1,"col":0},"declarationKind":"export"},{"kind":"function","name":"isValidIsbn10","nsQualifiers":"","location":{"filename":"books.js","line":22,"col":0},"declarationKind":"export"},{"kind":"function","name":"isValidIsbn","nsQualifiers":"","location":{"filename":"books.js","line":46,"col":0},"declarationKind":"export"},{"kind":"class","name":"HockeyGame","nsQualifiers":"","location":{"filename":"hockey.js","line":1,"col":0},"declarationKind":"export"},{"kind":"variable","name":"INFINITY","nsQualifiers":"","location":{"filename":"stats.js","line":5,"col":13},"declarationKind":"export"},{"kind":"function","name":"average","nsQualifiers":"","location":{"filename":"stats.js","line":13,"col":0},"declarationKind":"export"},{"kind":"function","name":"std","nsQualifiers":"","location":{"filename":"stats.js","line":33,"col":0},"declarationKind":"export"}]};
|
||||||
|
})()
|
||||||
+167
@@ -0,0 +1,167 @@
|
|||||||
|
<!DOCTYPE html>
|
||||||
|
<html>
|
||||||
|
<head>
|
||||||
|
<title>std - https://example.com/foo/ba documentation</title>
|
||||||
|
<meta charset="utf-8">
|
||||||
|
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
||||||
|
<meta name="doc-current-symbol" content="std">
|
||||||
|
<link rel="stylesheet" href="./styles.css">
|
||||||
|
</head>
|
||||||
|
<body>
|
||||||
|
|
||||||
|
|
||||||
|
<nav id="sidepanel">
|
||||||
|
<h2><a href="index.html"><span>https://example.com/foo/ba</span></a></h2>
|
||||||
|
|
||||||
|
<div class="section_title"><div class="symbol_kind kind_Class_text kind_Class_bg" title="Class">
|
||||||
|
c
|
||||||
|
</div>
|
||||||
|
<h3 class="kind_Class_text">Classes</h3></div>
|
||||||
|
<ul>
|
||||||
|
|
||||||
|
<li>
|
||||||
|
<a href="HockeyGame.html" title="HockeyGame" class=""><span><code>HockeyGame</code></span></a>
|
||||||
|
</li>
|
||||||
|
|
||||||
|
</ul>
|
||||||
|
|
||||||
|
<div class="section_title"><div class="symbol_kind kind_Function_text kind_Function_bg" title="Function">
|
||||||
|
f
|
||||||
|
</div>
|
||||||
|
<h3 class="kind_Function_text">Functions</h3></div>
|
||||||
|
<ul>
|
||||||
|
|
||||||
|
<li>
|
||||||
|
<a href="average.html" title="average" class=""><span><code>average</code></span></a>
|
||||||
|
</li>
|
||||||
|
|
||||||
|
<li>
|
||||||
|
<a href="isValidIsbn.html" title="isValidIsbn" class=""><span><code>isValidIsbn</code></span></a>
|
||||||
|
</li>
|
||||||
|
|
||||||
|
<li>
|
||||||
|
<a href="isValidIsbn10.html" title="isValidIsbn10" class=""><span><code>isValidIsbn10</code></span></a>
|
||||||
|
</li>
|
||||||
|
|
||||||
|
<li>
|
||||||
|
<a href="isValidIsbn13.html" title="isValidIsbn13" class=""><span><code>isValidIsbn13</code></span></a>
|
||||||
|
</li>
|
||||||
|
|
||||||
|
<li>
|
||||||
|
<a href="std.html" title="std" class=""><span><code>std</code></span></a>
|
||||||
|
</li>
|
||||||
|
|
||||||
|
</ul>
|
||||||
|
|
||||||
|
<div class="section_title"><div class="symbol_kind kind_Variable_text kind_Variable_bg" title="Variable">
|
||||||
|
v
|
||||||
|
</div>
|
||||||
|
<h3 class="kind_Variable_text">Variables</h3></div>
|
||||||
|
<ul>
|
||||||
|
|
||||||
|
<li>
|
||||||
|
<a href="INFINITY.html" title="INFINITY" class=""><span><code>INFINITY</code></span></a>
|
||||||
|
</li>
|
||||||
|
|
||||||
|
</ul>
|
||||||
|
|
||||||
|
</nav>
|
||||||
|
|
||||||
|
|
||||||
|
<div id="content">
|
||||||
|
<a href="./index.html">← Back to index</a>
|
||||||
|
<input type="text" id="searchbar" style="display: none;" />
|
||||||
|
|
||||||
|
<main class="symbol_group" id="symbol_std">
|
||||||
|
|
||||||
|
<article class="symbol">
|
||||||
|
<div class="symbol_header">
|
||||||
|
<div class="doc_block_title">
|
||||||
|
<div>
|
||||||
|
<span class="kind_Function_text">function</span> <span style="font-weight: 700;">std</span>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<div>
|
||||||
|
|
||||||
|
<style scoped>
|
||||||
|
|
||||||
|
#function_std_0 {
|
||||||
|
display: none;
|
||||||
|
}
|
||||||
|
#function_std_0:checked ~ *:last-child > :not(#function_std_0_div) {
|
||||||
|
display: none;
|
||||||
|
}
|
||||||
|
#function_std_0:checked ~ div:first-of-type > label[for='function_std_0'] {
|
||||||
|
background-color: #056CF00C;
|
||||||
|
border: solid 2px rgb(37 99 235);
|
||||||
|
cursor: unset;
|
||||||
|
}
|
||||||
|
#function_std_0:checked ~ div:first-of-type > label[for='function_std_0'] > code {
|
||||||
|
margin: -1px;
|
||||||
|
}
|
||||||
|
|
||||||
|
</style>
|
||||||
|
<input type="radio" name="function_std" id="function_std_0" checked />
|
||||||
|
|
||||||
|
<div class="function_overload_selectors">
|
||||||
|
|
||||||
|
<label for="function_std_0" class="function_overload_label">
|
||||||
|
<code>
|
||||||
|
<span style="font-weight: 700;">std</span><span style="font-weight: 500;">(<span><span>lst</span></span>)</span>
|
||||||
|
</code>
|
||||||
|
|
||||||
|
</label>
|
||||||
|
|
||||||
|
</div>
|
||||||
|
<div>
|
||||||
|
<div class="doc_block_items" id="function_std_0_div"><div class="markdown_summary"><p>Computes the standard deviation of the list. If the list is empty, the
|
||||||
|
function returns NaN</p>
|
||||||
|
</div><div>
|
||||||
|
Parameters
|
||||||
|
<div class="section">
|
||||||
|
<div class="doc_item" id="function_std_0_parameters_lst">
|
||||||
|
|
||||||
|
<a
|
||||||
|
href="#function_std_0_parameters_lst"
|
||||||
|
class="anchor"
|
||||||
|
aria-label="Anchor"
|
||||||
|
tabIndex=-1
|
||||||
|
>
|
||||||
|
<div style="width: 14px; height: 14px; display: inline-block;">🔗</div>
|
||||||
|
</a>
|
||||||
|
|
||||||
|
<div class="doc_entry">
|
||||||
|
<span class="doc_entry_children">
|
||||||
|
<code>
|
||||||
|
<span style="font-weight: 700;">lst</span><span style="font-weight: 500;">
|
||||||
|
|
||||||
|
</span>
|
||||||
|
</code>
|
||||||
|
</span>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div><div>
|
||||||
|
Return Type
|
||||||
|
<div class="section">
|
||||||
|
|
||||||
|
</div>
|
||||||
|
</div></div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</article>
|
||||||
|
|
||||||
|
</main>
|
||||||
|
|
||||||
|
|
||||||
|
<div id="searchResults"></div>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
</body>
|
||||||
|
<script src="./search_index.js" defer></script>
|
||||||
|
<script src="./fuse.js" defer></script>
|
||||||
|
<script src="./search.js" defer></script>
|
||||||
|
</html>
|
||||||
+475
@@ -0,0 +1,475 @@
|
|||||||
|
:root {
|
||||||
|
font-family: sans-serif;
|
||||||
|
--general-border-radius: 10px;
|
||||||
|
}
|
||||||
|
body {
|
||||||
|
margin: 0;
|
||||||
|
background-color: rgb(231 229 228);
|
||||||
|
display: flex;
|
||||||
|
}
|
||||||
|
table {
|
||||||
|
border-color: inherit;
|
||||||
|
border-collapse: collapse;
|
||||||
|
}
|
||||||
|
#content {
|
||||||
|
padding: 30px;
|
||||||
|
width: 100%;
|
||||||
|
background-color: white;
|
||||||
|
border-radius: var(--general-border-radius) 0 0 var(--general-border-radius);
|
||||||
|
overflow-y: auto;
|
||||||
|
}
|
||||||
|
#content > h2 {
|
||||||
|
margin: 0;
|
||||||
|
}
|
||||||
|
p {
|
||||||
|
margin: 0;
|
||||||
|
}
|
||||||
|
a {
|
||||||
|
color: inherit;
|
||||||
|
text-decoration: inherit;
|
||||||
|
}
|
||||||
|
.link {
|
||||||
|
color: rgb(37 99 235);
|
||||||
|
transition-property: color;
|
||||||
|
transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1);
|
||||||
|
transition-duration: 75ms;
|
||||||
|
}
|
||||||
|
.link:hover {
|
||||||
|
color: rgb(96 165 250);
|
||||||
|
}
|
||||||
|
#sidepanel {
|
||||||
|
flex-shrink: 0;
|
||||||
|
padding: 12px 0 12px 12px;
|
||||||
|
height: 100vh;
|
||||||
|
width: fit-content;
|
||||||
|
min-width: 12%;
|
||||||
|
max-width: 22%;
|
||||||
|
top: 0;
|
||||||
|
left: 0;
|
||||||
|
overflow-y: scroll;
|
||||||
|
position: sticky;
|
||||||
|
box-sizing: border-box;
|
||||||
|
overscroll-behavior-y: contain;
|
||||||
|
scrollbar-width: thin;
|
||||||
|
}
|
||||||
|
#sidepanel ul {
|
||||||
|
list-style: none;
|
||||||
|
padding-left: 16px;
|
||||||
|
}
|
||||||
|
#sidepanel li {
|
||||||
|
display: block;
|
||||||
|
margin: -2px 0;
|
||||||
|
}
|
||||||
|
#sidepanel a {
|
||||||
|
display: block;
|
||||||
|
padding: 8px 16px 8px 8px;
|
||||||
|
border-radius: var(--general-border-radius) 0 0 var(--general-border-radius);
|
||||||
|
position: relative;
|
||||||
|
}
|
||||||
|
#sidepanel a span {
|
||||||
|
display: block;
|
||||||
|
width: 100%;
|
||||||
|
overflow: hidden;
|
||||||
|
white-space: nowrap;
|
||||||
|
text-overflow: ellipsis;
|
||||||
|
}
|
||||||
|
#sidepanel a:hover, #sidepanel a .active {
|
||||||
|
background-color: white;
|
||||||
|
}
|
||||||
|
#sidepanel a:hover::before, #sidepanel a .active::before {
|
||||||
|
content: "";
|
||||||
|
position: absolute;
|
||||||
|
|
||||||
|
background-color: transparent;
|
||||||
|
top: calc(var(--general-border-radius) * -2);
|
||||||
|
right: 0;
|
||||||
|
height: calc(var(--general-border-radius) * 2);
|
||||||
|
width: var(--general-border-radius);
|
||||||
|
border-bottom-right-radius: var(--general-border-radius);
|
||||||
|
box-shadow: 0 var(--general-border-radius) 0 0 white;
|
||||||
|
}
|
||||||
|
#sidepanel a:hover::after, #sidepanel a .active::after {
|
||||||
|
content: "";
|
||||||
|
position: absolute;
|
||||||
|
|
||||||
|
background-color: transparent;
|
||||||
|
bottom: calc(var(--general-border-radius) * -2);
|
||||||
|
right: 0;
|
||||||
|
height: calc(var(--general-border-radius) * 2);
|
||||||
|
width: var(--general-border-radius);
|
||||||
|
border-top-right-radius: var(--general-border-radius);
|
||||||
|
box-shadow: 0 calc(var(--general-border-radius) * -1) 0 0 white;
|
||||||
|
}
|
||||||
|
#sidepanel .section_title {
|
||||||
|
display: flex;
|
||||||
|
align-items: center;
|
||||||
|
gap: 10px;
|
||||||
|
margin: 10px 20px 10px 0;
|
||||||
|
}
|
||||||
|
#sidepanel .section_title h3 {
|
||||||
|
margin: 0;
|
||||||
|
line-height: 1;
|
||||||
|
}
|
||||||
|
|
||||||
|
#searchbar {
|
||||||
|
width: 100%;
|
||||||
|
padding: 0.575rem;
|
||||||
|
box-sizing: border-box;
|
||||||
|
border: none;
|
||||||
|
background-color: rgb(231 229 228);
|
||||||
|
border-radius: 10px;
|
||||||
|
font-size: 1rem;
|
||||||
|
margin: 1.5rem 0;
|
||||||
|
}
|
||||||
|
#searchResults ul {
|
||||||
|
list-style: none;
|
||||||
|
padding: 0;
|
||||||
|
}
|
||||||
|
#searchResults ul li {
|
||||||
|
display: block;
|
||||||
|
}
|
||||||
|
#searchResults ul a {
|
||||||
|
display: flex;
|
||||||
|
gap: 1rem;
|
||||||
|
align-items: center;
|
||||||
|
padding: 10px 12px;
|
||||||
|
justify-content: space-between;
|
||||||
|
line-height: 1;
|
||||||
|
}
|
||||||
|
#searchResults ul a div:first-child {
|
||||||
|
display: flex;
|
||||||
|
gap: 10px;
|
||||||
|
align-items: center;
|
||||||
|
}
|
||||||
|
#searchResults ul a div:last-child {
|
||||||
|
color: gray;
|
||||||
|
font-style: italic;
|
||||||
|
}
|
||||||
|
|
||||||
|
#searchResults ul a:hover {
|
||||||
|
background-color: rgb(243 244 246);
|
||||||
|
}
|
||||||
|
|
||||||
|
#searchResults ul > * + * {
|
||||||
|
border-top: 1px solid rgb(209 213 219);
|
||||||
|
}
|
||||||
|
|
||||||
|
/* doc classes */
|
||||||
|
.symbol_group > * + * {
|
||||||
|
margin-top: 3rem;
|
||||||
|
/* 48px */
|
||||||
|
}
|
||||||
|
.symbol > * + * {
|
||||||
|
margin-top: 2rem;
|
||||||
|
/* 32px */
|
||||||
|
}
|
||||||
|
.symbol_header {
|
||||||
|
display: flex;
|
||||||
|
justify-content: space-between;
|
||||||
|
align-items: flex-start;
|
||||||
|
}
|
||||||
|
.doc_block_items > * + * {
|
||||||
|
margin-top: 1.75rem;
|
||||||
|
/* 28px */
|
||||||
|
}
|
||||||
|
.doc_block_title {
|
||||||
|
font-weight: 500;
|
||||||
|
background-color: unset !important;
|
||||||
|
}
|
||||||
|
.doc_block_title > * + * {
|
||||||
|
margin-top: 0.25rem;
|
||||||
|
/* 4px */
|
||||||
|
}
|
||||||
|
.doc_block_title > *:first-child {
|
||||||
|
font-size: 1.25rem;
|
||||||
|
/* 20px */
|
||||||
|
line-height: 1.75rem;
|
||||||
|
/* 28px */
|
||||||
|
}
|
||||||
|
.doc_block_subtitle {
|
||||||
|
font-size: 0.875rem; /* 14px */
|
||||||
|
line-height: 1rem; /* 16px */
|
||||||
|
}
|
||||||
|
.doc_block_subtitle > * + * {
|
||||||
|
margin-top: 0.125rem; /* 2px */
|
||||||
|
}
|
||||||
|
.doc_block_subtitle_text {
|
||||||
|
color: rgb(156 163 175);
|
||||||
|
font-style: italic;
|
||||||
|
}
|
||||||
|
.section_title {
|
||||||
|
font-size: 0.875rem;
|
||||||
|
/* 14px */
|
||||||
|
line-height: 1.5rem;
|
||||||
|
/* 24px */
|
||||||
|
font-weight: 500;
|
||||||
|
color: rgb(156 163 175);
|
||||||
|
padding-top: 0.25rem;
|
||||||
|
/* 4px */
|
||||||
|
padding-bottom: 0.25rem;
|
||||||
|
/* 4px */
|
||||||
|
}
|
||||||
|
.section {
|
||||||
|
margin-top: 0.5rem;
|
||||||
|
/* 8px */
|
||||||
|
}
|
||||||
|
.section > * + * {
|
||||||
|
margin-top: 1.75rem;
|
||||||
|
/* 28px */
|
||||||
|
}
|
||||||
|
.doc_item {
|
||||||
|
/* TODO: group */
|
||||||
|
position: relative;
|
||||||
|
}
|
||||||
|
.doc_item:hover .anchor {
|
||||||
|
display: block;
|
||||||
|
}
|
||||||
|
.doc_entry {
|
||||||
|
display: flex;
|
||||||
|
justify-content: space-between;
|
||||||
|
}
|
||||||
|
.doc_entry_children {
|
||||||
|
display: flex;
|
||||||
|
align-items: center;
|
||||||
|
overflow-wrap: break-word;
|
||||||
|
gap: 0.5rem;
|
||||||
|
/* 8px */
|
||||||
|
}
|
||||||
|
.function_overload_selectors > * + * {
|
||||||
|
margin-top: 0.5rem; /* 8px */
|
||||||
|
}
|
||||||
|
.function_overload_label {
|
||||||
|
display: block;
|
||||||
|
padding: 1rem; /* 16px */
|
||||||
|
border-radius: 0.5rem; /* 8px */
|
||||||
|
border: 1px solid rgb(209 213 219);
|
||||||
|
cursor: pointer;
|
||||||
|
}
|
||||||
|
.function_overload_label:hover {
|
||||||
|
border-color: rgb(243 244 246);
|
||||||
|
}
|
||||||
|
|
||||||
|
.symbol_section {
|
||||||
|
display: block;
|
||||||
|
}
|
||||||
|
|
||||||
|
.symbol_section > tr {
|
||||||
|
display: block;
|
||||||
|
}
|
||||||
|
|
||||||
|
.symbol_section_symbol {
|
||||||
|
display: block;
|
||||||
|
padding-top: 0.25rem; /* 4px */
|
||||||
|
padding-bottom: 0.25rem; /* 4px */
|
||||||
|
padding-right: 0.75rem; /* 12px */
|
||||||
|
font-weight: 700;
|
||||||
|
}
|
||||||
|
|
||||||
|
.symbol_section_symbol > div {
|
||||||
|
min-width: 13rem;
|
||||||
|
display: flex;
|
||||||
|
align-items: center;
|
||||||
|
}
|
||||||
|
|
||||||
|
.symbol_section_symbol > div > * + * {
|
||||||
|
margin-left: 0.5rem; /* 8px */
|
||||||
|
}
|
||||||
|
|
||||||
|
.symbol_section_doc {
|
||||||
|
display: block;
|
||||||
|
padding-top: 0.25rem; /* 4px */
|
||||||
|
padding-bottom: 0.25rem; /* 4px */
|
||||||
|
font-size: 0.875rem; /* 14px */
|
||||||
|
line-height: 1.25rem; /* 20px */
|
||||||
|
color: rgb(107 114 128);
|
||||||
|
}
|
||||||
|
|
||||||
|
@media (min-width: 1024px) {
|
||||||
|
.symbol_section {
|
||||||
|
display: table;
|
||||||
|
}
|
||||||
|
|
||||||
|
.symbol_section > tr {
|
||||||
|
display: table-row;
|
||||||
|
}
|
||||||
|
|
||||||
|
.symbol_section_symbol {
|
||||||
|
display: table-cell;
|
||||||
|
}
|
||||||
|
|
||||||
|
.symbol_section_doc {
|
||||||
|
display: table-cell;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
.anchor {
|
||||||
|
float: left;
|
||||||
|
line-height: 1;
|
||||||
|
display: none;
|
||||||
|
color: rgb(75 85 99);
|
||||||
|
margin-left: -18px;
|
||||||
|
padding-right: 4px;
|
||||||
|
}
|
||||||
|
.anchor:hover {
|
||||||
|
display: block;
|
||||||
|
}
|
||||||
|
.kind_Function_text {
|
||||||
|
color: #056CF0;
|
||||||
|
}
|
||||||
|
.kind_Function_bg {
|
||||||
|
background-color: #026BEB1A;
|
||||||
|
}
|
||||||
|
.kind_Variable_text {
|
||||||
|
color: #7E57C0;
|
||||||
|
}
|
||||||
|
.kind_Variable_bg {
|
||||||
|
background-color: #7E57C01A;
|
||||||
|
}
|
||||||
|
.kind_Class_text {
|
||||||
|
color: #20B44B;
|
||||||
|
}
|
||||||
|
.kind_Class_bg {
|
||||||
|
background-color: #2FA8501A;
|
||||||
|
}
|
||||||
|
.kind_Enum_text {
|
||||||
|
color: #22ABB0;
|
||||||
|
}
|
||||||
|
.kind_Enum_bg {
|
||||||
|
background-color: #22ABB01A;
|
||||||
|
}
|
||||||
|
.kind_Interface_text {
|
||||||
|
color: #D2A064;
|
||||||
|
}
|
||||||
|
.kind_Interface_bg {
|
||||||
|
background-color: #D4A0681A;
|
||||||
|
}
|
||||||
|
.kind_TypeAlias_text {
|
||||||
|
color: #A4478C;
|
||||||
|
}
|
||||||
|
.kind_TypeAlias_bg {
|
||||||
|
background-color: #A4478C1A;
|
||||||
|
}
|
||||||
|
.kind_Namespace_text {
|
||||||
|
color: #D25646;
|
||||||
|
}
|
||||||
|
.kind_Namespace_bg {
|
||||||
|
background-color: #D256461A;
|
||||||
|
}
|
||||||
|
|
||||||
|
.symbol_kind {
|
||||||
|
border-radius: 50%;
|
||||||
|
width: 1.5rem; /* 24px */
|
||||||
|
height: 1.5rem; /* 24px */
|
||||||
|
display: inline-flex;
|
||||||
|
align-items: center;
|
||||||
|
justify-content: center;
|
||||||
|
font-weight: 500;
|
||||||
|
font-size: 0.75rem; /* 12px */
|
||||||
|
line-height: 1;
|
||||||
|
flex-shrink: 0;
|
||||||
|
user-select: none;
|
||||||
|
}
|
||||||
|
|
||||||
|
/* markdown */
|
||||||
|
.markdown > * + * {
|
||||||
|
margin-top: 1rem; /* 16px */
|
||||||
|
}
|
||||||
|
|
||||||
|
.markdown :not(pre) > code {
|
||||||
|
/* TODO: font-mono */
|
||||||
|
|
||||||
|
font-size: 0.875rem; /* 14px */
|
||||||
|
line-height: 1.25rem; /* 20px */
|
||||||
|
padding: 0.25rem 0.375rem; /* 4px 6px */
|
||||||
|
border-radius: 0.25rem; /* 4px */
|
||||||
|
background-color: rgb(243 244 246);
|
||||||
|
}
|
||||||
|
|
||||||
|
.markdown pre {
|
||||||
|
/* TODO: font-mono */
|
||||||
|
|
||||||
|
font-size: 0.875rem; /* 14px */
|
||||||
|
line-height: 1.25rem; /* 20px */
|
||||||
|
padding: 0.625rem; /* 10px */
|
||||||
|
border-radius: 0.5rem; /* 8px */
|
||||||
|
color: black;
|
||||||
|
background-color: rgb(243 244 246);
|
||||||
|
overflow-x: auto;
|
||||||
|
}
|
||||||
|
|
||||||
|
.markdown a {
|
||||||
|
color: rgb(37 99 235);
|
||||||
|
transition-property: color;
|
||||||
|
transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1);
|
||||||
|
transition-duration: 75ms;
|
||||||
|
}
|
||||||
|
.markdown a:hover {
|
||||||
|
color: rgb(96 165 250);
|
||||||
|
}
|
||||||
|
|
||||||
|
.markdown p {
|
||||||
|
margin: 0.25rem 0; /* 4px */
|
||||||
|
text-align: left;
|
||||||
|
}
|
||||||
|
|
||||||
|
.markdown table {
|
||||||
|
table-layout: auto;
|
||||||
|
}
|
||||||
|
|
||||||
|
.markdown td {
|
||||||
|
padding: 0.5rem; /* 8px */
|
||||||
|
border: 1px solid rgb(107 114 128);
|
||||||
|
}
|
||||||
|
|
||||||
|
.markdown th {
|
||||||
|
font-weight: 700;
|
||||||
|
text-align: center;
|
||||||
|
}
|
||||||
|
|
||||||
|
.markdown_summary {
|
||||||
|
display: inline;
|
||||||
|
color: rgb(75 85 99);
|
||||||
|
}
|
||||||
|
|
||||||
|
.markdown_summary p {
|
||||||
|
display: inline-block;
|
||||||
|
}
|
||||||
|
|
||||||
|
.markdown_summary a {
|
||||||
|
color: rgb(37 99 235);
|
||||||
|
transition-property: color;
|
||||||
|
transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1);
|
||||||
|
transition-duration: 75ms;
|
||||||
|
}
|
||||||
|
.markdown_summary a:hover {
|
||||||
|
color: rgb(96 165 250);
|
||||||
|
}
|
||||||
|
.markdown_summary :not(pre) > code {
|
||||||
|
/* TODO: font-mono */
|
||||||
|
|
||||||
|
font-size: 0.875rem; /* 14px */
|
||||||
|
line-height: 1.25rem; /* 20px */
|
||||||
|
padding: 0.125rem 0.25rem; /* 2px 4px */
|
||||||
|
border-radius: 0.25rem; /* 4px */
|
||||||
|
background-color: rgb(243 244 246);
|
||||||
|
}
|
||||||
|
|
||||||
|
.example > details .arrow_toggle {
|
||||||
|
color: rgb(75 85 99);
|
||||||
|
}
|
||||||
|
.example > details[open] .arrow_toggle {
|
||||||
|
transform: rotate(90deg);
|
||||||
|
}
|
||||||
|
.example > details > summary {
|
||||||
|
list-style: none;
|
||||||
|
display: flex;
|
||||||
|
align-items: center;
|
||||||
|
gap: 0.5rem; /* 8px */
|
||||||
|
padding: 0.5rem 0.75rem; /* 8px 12px */
|
||||||
|
border-radius: 0.5rem; /* 8px */
|
||||||
|
width: 100%;
|
||||||
|
line-height: 1.5rem; /* 24px */
|
||||||
|
}
|
||||||
|
.example > details > summary::-webkit-details-marker {
|
||||||
|
display: none;
|
||||||
|
}
|
||||||
@@ -1,6 +1,24 @@
|
|||||||
<!doctype html>
|
<!DOCTYPE html>
|
||||||
|
<html lang="en">
|
||||||
<body>
|
<head>
|
||||||
<script src="script.js" type="module"></script>
|
<script src="script.js" type="module"></script>
|
||||||
<button id="foo">boom</button>
|
<meta charset="utf-8">
|
||||||
|
<title>title</title>
|
||||||
|
</head>
|
||||||
|
<body>
|
||||||
|
|
||||||
|
<div>
|
||||||
|
|
||||||
|
<input type="text" id="input-1" />
|
||||||
|
<div>
|
||||||
|
<button id="button-1">button-1</button>
|
||||||
|
</div>
|
||||||
|
<div>
|
||||||
|
<button id="button-2">button-2</button>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<pre id="output-1"></pre>
|
||||||
|
</div>
|
||||||
|
|
||||||
</body>
|
</body>
|
||||||
|
</html>
|
||||||
@@ -1,8 +1,12 @@
|
|||||||
|
import {std as average} from "https://cdn.jsdelivr.net/gh/didiercrunch/cours-420-301-ah@main/modules-examples/stats.js";
|
||||||
|
import {isValidIsbn} from "https://cdn.jsdelivr.net/gh/didiercrunch/cours-420-301-ah@main/modules-examples/books.js";
|
||||||
export function toto(){
|
export function toto(){
|
||||||
|
console.log(average([10, 15]));
|
||||||
console.log("say toto");
|
console.log("say toto");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
alert(isValidIsbn("ddd"))
|
||||||
|
|
||||||
export function hello(){
|
export function hello(){
|
||||||
console.log("say hello");
|
console.log("say hello");
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -0,0 +1,38 @@
|
|||||||
|
export class HockeyGame{
|
||||||
|
constructor(){
|
||||||
|
this.home = 0
|
||||||
|
this.away = 0
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Call this method when home team scores. It will
|
||||||
|
* increase home team score by 1 point.
|
||||||
|
*/
|
||||||
|
homeTeamScores(){
|
||||||
|
this.home += 1;
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Call this method when away team scores. It will
|
||||||
|
* increase home team score by 1 point.
|
||||||
|
*/
|
||||||
|
awayTeamScores(){
|
||||||
|
this.away += 1;
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Returns winner of the game.
|
||||||
|
*
|
||||||
|
* @returns {string} the name of the winner team. Either "home", "away" or "tie"
|
||||||
|
*/
|
||||||
|
winner(){
|
||||||
|
if(this.home > this.away){
|
||||||
|
return "home"
|
||||||
|
}
|
||||||
|
if(this.away > this.home){
|
||||||
|
return "away"
|
||||||
|
}
|
||||||
|
return "tie"
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
@@ -1,5 +1,15 @@
|
|||||||
|
|
||||||
|
/**
|
||||||
|
* In statistics, infinity is set to 30.
|
||||||
|
*/
|
||||||
export const INFINITY = 30;
|
export const INFINITY = 30;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Computes the average of the list. If the list is empty, the
|
||||||
|
* function returns NaN
|
||||||
|
* @param {number[]} lst
|
||||||
|
* @returns the average of the list.
|
||||||
|
*/
|
||||||
export function average(lst){
|
export function average(lst){
|
||||||
if(lst.length < 1){
|
if(lst.length < 1){
|
||||||
return NaN;
|
return NaN;
|
||||||
@@ -14,6 +24,12 @@ export function average(lst){
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Computes the standard deviation of the list. If the list is empty, the
|
||||||
|
* function returns NaN
|
||||||
|
* @param {number[]} lst
|
||||||
|
* @returns the standard deviation of the list.
|
||||||
|
*/
|
||||||
export function std(lst){
|
export function std(lst){
|
||||||
if(lst.length < 1){
|
if(lst.length < 1){
|
||||||
return NaN;
|
return NaN;
|
||||||
|
|||||||
Reference in new issue
Block a user