fix formatting in docs
This commit is contained in:
parent
30879a1d78
commit
b559118832
27 changed files with 248 additions and 116 deletions
|
|
@ -90,7 +90,7 @@
|
|||
<li>gracefully degrade on IE exceptions when setting invalid values</li>
|
||||
<li>fixes for Typescript definition file</li>
|
||||
<li>fixed bug in keys algorithm when mixing keyed and unkeyed elements <a href="https://github.com/lhorie/mithril.js/issues/246">#246</a></li>
|
||||
<li>added promise exception monitor and reverted promise exception handling semantics to v0.1.19 semantics (see [mithril.deferred.html#unchecked-error-handling]</li>
|
||||
<li>added promise exception monitor and reverted promise exception handling semantics to v0.1.19 semantics (see <a href="mithril.deferred.html#unchecked-error-handling">docs</a>)</li>
|
||||
<li>fixed redraw scheduling bug in old version of IE</li>
|
||||
<li>fixed incorrect diff when document is root, and html element is omitted</li>
|
||||
<li>fixed querystring clobbering in links w/ config:m.route <a href="https://github.com/lhorie/mithril.js/issues/261">#261</a></li>
|
||||
|
|
|
|||
|
|
@ -77,10 +77,12 @@
|
|||
<div class="col(9,9,12)">
|
||||
<h2 id="m-startcomputation-m-endcomputation">m.startComputation / m.endComputation</h2>
|
||||
<hr>
|
||||
<p><a href="#how-auto-redrawing-works">How auto-redrawing-works</a>
|
||||
<a href="#integrating-multiple-execution-threads">Integrating multiple execution threads</a>
|
||||
<a href="#integrating-to-legacy-code">Integrating to legacy code</a>
|
||||
<a href="#signature">Signature</a></p>
|
||||
<ul>
|
||||
<li><a href="#how-auto-redrawing-works">How auto-redrawing-works</a></li>
|
||||
<li><a href="#integrating-multiple-execution-threads">Integrating multiple execution threads</a></li>
|
||||
<li><a href="#integrating-to-legacy-code">Integrating to legacy code</a></li>
|
||||
<li><a href="#signature">Signature</a></li>
|
||||
</ul>
|
||||
<hr>
|
||||
<p>Typically, <code>m.startComputation</code> / <code>m.endComputation</code> don't need to be called from application space. These methods are only intended to be used by people who are writing libraries that do things asynchronously, or when calling vanilla javascript asynchronous functions from template <a href="mithril.html#accessing-the-real-dom"><code>config</code></a> functions.</p>
|
||||
<p>If you need to do custom asynchronous calls without using Mithril's API, and find that your views are not redrawing, or that you're being forced to call <a href="mithril.redraw.html"><code>m.redraw</code></a> manually, you should consider using <code>m.startComputation</code> / <code>m.endComputation</code> so that Mithril can intelligently auto-redraw once your custom code finishes running.</p>
|
||||
|
|
|
|||
|
|
@ -77,12 +77,14 @@
|
|||
<div class="col(9,9,12)">
|
||||
<h2 id="m-deferred">m.deferred</h2>
|
||||
<hr>
|
||||
<p><a href="#usage">Usage</a>
|
||||
<a href="#retrieving-a-value-via-the-getter-setter-api">Retrieving a value via the getter-setter API</a>
|
||||
<a href="#integrating-to-the-mithril-redrawing-system">Integrating to the Mithril redrawing system</a>
|
||||
<a href="#differences-from-promises-a-">Differences from Promises/A+</a>
|
||||
<a href="#the-exception-monitor">The exception monitor</a>
|
||||
<a href="#signature">Signature</a></p>
|
||||
<ul>
|
||||
<li><a href="#usage">Usage</a></li>
|
||||
<li><a href="#retrieving-a-value-via-the-getter-setter-api">Retrieving a value via the getter-setter API</a></li>
|
||||
<li><a href="#integrating-to-the-mithril-redrawing-system">Integrating to the Mithril redrawing system</a></li>
|
||||
<li><a href="#differences-from-promises-a-">Differences from Promises/A+</a></li>
|
||||
<li><a href="#the-exception-monitor">The exception monitor</a></li>
|
||||
<li><a href="#signature">Signature</a></li>
|
||||
</ul>
|
||||
<hr>
|
||||
<p>This is a low-level method in Mithril. It's a modified version of the Thenable API.</p>
|
||||
<p>A deferred is an asynchrony monad. It exposes a <code>promise</code> property which can <em>bind</em> callbacks to build a computation tree.</p>
|
||||
|
|
|
|||
|
|
@ -77,8 +77,10 @@
|
|||
<div class="col(9,9,12)">
|
||||
<h2 id="m-deps">m.deps</h2>
|
||||
<hr>
|
||||
<p><a href="#usage">Usage</a>
|
||||
<a href="#signature">Signature</a></p>
|
||||
<ul>
|
||||
<li><a href="#usage">Usage</a></li>
|
||||
<li><a href="#signature">Signature</a></li>
|
||||
</ul>
|
||||
<hr>
|
||||
<p>This function overwrites the reference to the <code>window</code> object that is used internally by Mithril. It is useful for injecting a mock <code>window</code> dependency for the purposes of testing and for running Mithril in non-browser environments. The mock object used by Mithril for its own test suite <a href="https://github.com/lhorie/mithril.js/blob/next/tests/mock.js">can be found in the development repo</a>.</p>
|
||||
<p>By default, Mithril uses <code>window</code> itself as the dependency. Note that Mithril only uses the mock object for browser APIs such as the DOM API and <code>requestAnimationFrame</code>, but relies on the environment for ECMAScript features like <code>Object.keys</code>.</p>
|
||||
|
|
|
|||
|
|
@ -77,16 +77,18 @@
|
|||
<div class="col(9,9,12)">
|
||||
<h2 id="m">m</h2>
|
||||
<hr>
|
||||
<p><a href="#usage">Usage</a>
|
||||
<a href="#binding-to-data">Binding to data</a>
|
||||
<a href="#using-html-entities">Using HTML entities</a>
|
||||
<a href="#accessing-the-real-dom-element">Accessing the real DOM element</a>
|
||||
<a href="#persisting-config-data">Persisting config data</a>
|
||||
<a href="#destructors">Destructors</a>
|
||||
<a href="#svg">SVG</a>
|
||||
<a href="#dealing-with-focus">Dealing with focus</a>
|
||||
<a href="#dealing-with-sorting-and-deleting-in-lists">Dealing with sorting and deleting in lists</a>
|
||||
<a href="#signature">Signature</a></p>
|
||||
<ul>
|
||||
<li><a href="#usage">Usage</a></li>
|
||||
<li><a href="#binding-to-data">Binding to data</a></li>
|
||||
<li><a href="#using-html-entities">Using HTML entities</a></li>
|
||||
<li><a href="#accessing-the-real-dom-element">Accessing the real DOM element</a></li>
|
||||
<li><a href="#persisting-config-data">Persisting config data</a></li>
|
||||
<li><a href="#destructors">Destructors</a></li>
|
||||
<li><a href="#svg">SVG</a></li>
|
||||
<li><a href="#dealing-with-focus">Dealing with focus</a></li>
|
||||
<li><a href="#dealing-with-sorting-and-deleting-in-lists">Dealing with sorting and deleting in lists</a></li>
|
||||
<li><a href="#signature">Signature</a></li>
|
||||
</ul>
|
||||
<hr>
|
||||
<p>This is a convenience method to compose virtual elements that can be rendered via <a href="mithril.render.html"><code>m.render()</code></a>.</p>
|
||||
<p>You are encouraged to use CSS selectors to define virtual elements. See "Signature" section for details.</p>
|
||||
|
|
|
|||
Binary file not shown.
|
|
@ -77,9 +77,11 @@
|
|||
<div class="col(9,9,12)">
|
||||
<h2 id="m-module">m.module</h2>
|
||||
<hr>
|
||||
<p><a href="#usage">Usage</a>
|
||||
<a href="#unloading-modules">Unloading modules</a>
|
||||
<a href="#signature">Signature</a></p>
|
||||
<ul>
|
||||
<li><a href="#usage">Usage</a></li>
|
||||
<li><a href="#unloading-modules">Unloading modules</a></li>
|
||||
<li><a href="#signature">Signature</a></li>
|
||||
</ul>
|
||||
<hr>
|
||||
<p>A module is an Object with two keys: <code>controller</code> and <code>view</code>. Each of those should point to a Javascript function.</p>
|
||||
<p>When using <code>m.module</code>, Mithril instantiates controllers as if they were class constructors. However, controllers may return objects if you want to use that Javascript feature to have more fine-grained control over a controller's lifecycle.</p>
|
||||
|
|
|
|||
|
|
@ -77,10 +77,12 @@
|
|||
<div class="col(9,9,12)">
|
||||
<h2 id="m-prop">m.prop</h2>
|
||||
<hr>
|
||||
<p><a href="#usage">Usage</a>
|
||||
<a href="#third-party-promise-library-support">Third-party promise library support</a>
|
||||
<a href="#serializing-getter-setters">Serializing getter-setters</a>
|
||||
<a href="#signature">Signature</a></p>
|
||||
<ul>
|
||||
<li><a href="#usage">Usage</a></li>
|
||||
<li><a href="#third-party-promise-library-support">Third-party promise library support</a></li>
|
||||
<li><a href="#serializing-getter-setters">Serializing getter-setters</a></li>
|
||||
<li><a href="#signature">Signature</a></li>
|
||||
</ul>
|
||||
<hr>
|
||||
<p>This is a getter-setter factory utility. It returns a function that stores information.</p>
|
||||
<p>Note that modifying the values of <code>m.prop</code> getter-setters does not trigger redrawing. Instead, Mithril's redrawing system relies on <a href="mithril.computation.html"><code>m.startComputation</code> and <code>m.endComputation</code></a>. These functions are internally called by Mithril when you initialize a module via <a href="mithril.module.html"><code>m.module</code></a> or <a href="mithril.route.html"><code>m.route</code></a>, and when you trigger event handlers that were created within templates with <a href="mithril.html"><code>m()</code></a>. </p>
|
||||
|
|
|
|||
|
|
@ -77,10 +77,12 @@
|
|||
<div class="col(9,9,12)">
|
||||
<h2 id="m-redraw">m.redraw</h2>
|
||||
<hr>
|
||||
<p><a href="#changing-redraw-strategy">Changing redraw strategy</a>
|
||||
<a href="#preventing-redraws-on-events">Preventing redraws on events</a>
|
||||
<a href="#forcing-redraw">Forcing redraw</a>
|
||||
<a href="#signature">Signature</a></p>
|
||||
<ul>
|
||||
<li><a href="#changing-redraw-strategy">Changing redraw strategy</a></li>
|
||||
<li><a href="#preventing-redraws-on-events">Preventing redraws on events</a></li>
|
||||
<li><a href="#forcing-redraw">Forcing redraw</a></li>
|
||||
<li><a href="#signature">Signature</a></li>
|
||||
</ul>
|
||||
<hr>
|
||||
<p>Redraws the view for the currently active module. Use <a href="mithril.module.html"><code>m.module()</code></a> to activate a module.</p>
|
||||
<p>This method is called internally by Mithril's auto-redrawing system. Usually you don't need to call it manually unless you are doing recurring asynchronous operations (i.e. using <code>setInterval</code>) or if you want to decouple slow running background requests from the rendering context (see the <code>background</code> option in <a href="mithril.request.html"><code>m.request</code></a>.</p>
|
||||
|
|
|
|||
|
|
@ -77,9 +77,11 @@
|
|||
<div class="col(9,9,12)">
|
||||
<h2 id="m-render">m.render</h2>
|
||||
<hr>
|
||||
<p><a href="#usage">Usage</a>
|
||||
<a href="#subtree directives">Subtree directives</a>
|
||||
<a href="#signature">Signature</a></p>
|
||||
<ul>
|
||||
<li><a href="#usage">Usage</a></li>
|
||||
<li><a href="#subtree directives">Subtree directives</a></li>
|
||||
<li><a href="#signature">Signature</a></li>
|
||||
</ul>
|
||||
<hr>
|
||||
<p>This method generates a DOM tree inside of a given HTML element.</p>
|
||||
<p>If the method is run more than once with the same root element, it diffs the new tree against the existing one and intelligently modifies only the portions that have changed.</p>
|
||||
|
|
|
|||
|
|
@ -77,20 +77,22 @@
|
|||
<div class="col(9,9,12)">
|
||||
<h2 id="m-request">m.request</h2>
|
||||
<hr>
|
||||
<p><a href="#basic-usage">Basic usage</a>
|
||||
<a href="#processing-web-service-data">Processing-web-service-data</a>
|
||||
<a href="#bind-redirection-code">Bind redirection code</a>
|
||||
<a href="#binding-errors">Binding errors</a>
|
||||
<a href="#queuing-operations">Queuing operations</a>
|
||||
<a href="#casting-the-response-data-to-a-class">Casting the Response Data to a Class</a>
|
||||
<a href="#unwrapping-response-data">Unwrapping Response Data</a>
|
||||
<a href="#using-different-data-transfer-formats">Using Different Data Transfer Formats</a>
|
||||
<a href="#using-variable-data-formats">Using variable data formats</a>
|
||||
<a href="#extracting-metadata-from-the-response">Extracting Metadata from the Response</a>
|
||||
<a href="#custom-request-rejections">Custom request rejections</a>
|
||||
<a href="#configuring-the-underlying-xmlhttprequest">Configuring the underlying XMLHttpRequest</a>
|
||||
<a href="#aborting-a-request">Aborting a request</a>
|
||||
<a href="#signature">Signature</a></p>
|
||||
<ul>
|
||||
<li><a href="#basic-usage">Basic usage</a></li>
|
||||
<li><a href="#processing-web-service-data">Processing-web-service-data</a></li>
|
||||
<li><a href="#bind-redirection-code">Bind redirection code</a></li>
|
||||
<li><a href="#binding-errors">Binding errors</a></li>
|
||||
<li><a href="#queuing-operations">Queuing operations</a></li>
|
||||
<li><a href="#casting-the-response-data-to-a-class">Casting the Response Data to a Class</a></li>
|
||||
<li><a href="#unwrapping-response-data">Unwrapping Response Data</a></li>
|
||||
<li><a href="#using-different-data-transfer-formats">Using Different Data Transfer Formats</a></li>
|
||||
<li><a href="#using-variable-data-formats">Using variable data formats</a></li>
|
||||
<li><a href="#extracting-metadata-from-the-response">Extracting Metadata from the Response</a></li>
|
||||
<li><a href="#custom-request-rejections">Custom request rejections</a></li>
|
||||
<li><a href="#configuring-the-underlying-xmlhttprequest">Configuring the underlying XMLHttpRequest</a></li>
|
||||
<li><a href="#aborting-a-request">Aborting a request</a></li>
|
||||
<li><a href="#signature">Signature</a></li>
|
||||
</ul>
|
||||
<hr>
|
||||
<p>This is a high-level utility for working with web services, which allows writing asynchronous code relatively procedurally.</p>
|
||||
<p>By default, it assumes server responses are in JSON format and optionally instantiates a class with the response data.</p>
|
||||
|
|
|
|||
|
|
@ -77,13 +77,15 @@
|
|||
<div class="col(9,9,12)">
|
||||
<h2 id="m-route">m.route</h2>
|
||||
<hr>
|
||||
<p><a href="#defining-routes">Defining routes</a>
|
||||
<a href="#variadic-routes">Variadic routes</a>
|
||||
<a href="#routes-with-querystrings">Routes with querystrings</a>
|
||||
<a href="#running-clean-up-code-on-route-change">Running clean up code on route change</a>
|
||||
<a href="#redirecting">Redirecting</a>
|
||||
<a href="#reading-the-currently-active-route">Reading the currently active route</a>
|
||||
<a href="#mode abstraction">Mode abstraction</a></p>
|
||||
<ul>
|
||||
<li><a href="#defining-routes">Defining routes</a></li>
|
||||
<li><a href="#variadic-routes">Variadic routes</a></li>
|
||||
<li><a href="#routes-with-querystrings">Routes with querystrings</a></li>
|
||||
<li><a href="#running-clean-up-code-on-route-change">Running clean up code on route change</a></li>
|
||||
<li><a href="#redirecting">Redirecting</a></li>
|
||||
<li><a href="#reading-the-currently-active-route">Reading the currently active route</a></li>
|
||||
<li><a href="#mode abstraction">Mode abstraction</a></li>
|
||||
</ul>
|
||||
<hr>
|
||||
<p>Routing is a system that allows creating Single-Page-Applications (SPA), i.e. applications that can go from a page to another without causing a full browser refresh.</p>
|
||||
<p>It enables seamless navigability while preserving the ability to bookmark each page individually, and the ability to navigate the application via the browser's history mechanism.</p>
|
||||
|
|
|
|||
4
bubbles.html
Normal file
4
bubbles.html
Normal file
|
|
@ -0,0 +1,4 @@
|
|||
<script src="mithril.js"></script>
|
||||
<script type="text/javascript">
|
||||
|
||||
</script>
|
||||
98
chain.html
Normal file
98
chain.html
Normal file
|
|
@ -0,0 +1,98 @@
|
|||
<!doctype html>
|
||||
<html>
|
||||
<head>
|
||||
<title>Don't break the chain</title>
|
||||
</head>
|
||||
<body>
|
||||
<script src="mithril.js"></script>
|
||||
<script>
|
||||
//our app's namespace
|
||||
var chain = {};
|
||||
|
||||
//model
|
||||
chain.save = function(list) {
|
||||
localStorage["chain-app.list"] = JSON.stringify(list);
|
||||
};
|
||||
chain.load = function() {
|
||||
return JSON.parse(localStorage["chain-app.list"] || "[]");
|
||||
};
|
||||
|
||||
chain.today = function() {
|
||||
var now = new Date();
|
||||
return new Date(now.getFullYear(), now.getMonth(), now.getDate(), 0, 0, 0, 0);
|
||||
}
|
||||
chain.resetDate = function() {
|
||||
return localStorage["chain-app.start-date"] = chain.today().getTime();
|
||||
}
|
||||
chain.startDate = function() {
|
||||
return new Date(parseInt(localStorage["chain-app.start-date"] || chain.resetDate()));
|
||||
}
|
||||
chain.dateAt = function(index) {
|
||||
var date = new Date(chain.startDate());
|
||||
date.setDate(date.getDate() + index);
|
||||
return date;
|
||||
}
|
||||
|
||||
|
||||
|
||||
//controller
|
||||
chain.controller = function() {
|
||||
var list = chain.load();
|
||||
|
||||
this.isChecked = function(index) {
|
||||
return list[index]
|
||||
};
|
||||
this.check = function(index, status) {
|
||||
if (chain.dateAt(index).getTime() <= chain.today().getTime()) {
|
||||
list[index] = status;
|
||||
chain.save(list);
|
||||
}
|
||||
};
|
||||
};
|
||||
|
||||
|
||||
|
||||
//view
|
||||
chain.view = function(ctrl) {
|
||||
return m("table", chain.seven(function(y) {
|
||||
return m("tr", chain.seven(function(x) {
|
||||
var index = chain.indexAt(x, y)
|
||||
return m("td", chain.highlights(index), [
|
||||
m("input[type=checkbox]", chain.checks(ctrl, index))
|
||||
]);
|
||||
}));
|
||||
}));
|
||||
};
|
||||
|
||||
chain.seven = function(subject) {
|
||||
var output = [];
|
||||
for (var i = 0; i < 7; i++) output.push(subject(i));
|
||||
return output;
|
||||
};
|
||||
|
||||
chain.checks = function(ctrl, index) {
|
||||
return {
|
||||
onclick: function() {
|
||||
ctrl.check(index, this.checked);
|
||||
},
|
||||
checked: ctrl.isChecked(index)
|
||||
};
|
||||
};
|
||||
|
||||
chain.highlights = function(index) {
|
||||
return {
|
||||
style: {
|
||||
background: chain.dateAt(index).getTime() == chain.today().getTime() ? "silver" : ""
|
||||
}
|
||||
};
|
||||
};
|
||||
|
||||
chain.indexAt = function(x, y) {
|
||||
return y * 7 + x;
|
||||
}
|
||||
|
||||
//render it
|
||||
m.module(document.body, chain);
|
||||
</script>
|
||||
</body>
|
||||
</html>
|
||||
6
clientaccess.html
Normal file
6
clientaccess.html
Normal file
|
|
@ -0,0 +1,6 @@
|
|||
<body></body>
|
||||
<script src="mithril.js"></script>
|
||||
<script>
|
||||
m.render(document.body, [m("a", "a"), [m("b[key=b]", "b"), m("b[key=c]", "c"), m("b[key=d]", "d")]])
|
||||
m.render(document.body, [m("a", "a"), [m("b[key=c]", "c")]])
|
||||
</script>
|
||||
|
|
@ -15,7 +15,7 @@
|
|||
- gracefully degrade on IE exceptions when setting invalid values
|
||||
- fixes for Typescript definition file
|
||||
- fixed bug in keys algorithm when mixing keyed and unkeyed elements [#246](https://github.com/lhorie/mithril.js/issues/246)
|
||||
- added promise exception monitor and reverted promise exception handling semantics to v0.1.19 semantics (see [mithril.deferred.md#unchecked-error-handling]
|
||||
- added promise exception monitor and reverted promise exception handling semantics to v0.1.19 semantics (see [docs](mithril.deferred.md#unchecked-error-handling))
|
||||
- fixed redraw scheduling bug in old version of IE
|
||||
- fixed incorrect diff when document is root, and html element is omitted
|
||||
- fixed querystring clobbering in links w/ config:m.route [#261](https://github.com/lhorie/mithril.js/issues/261)
|
||||
|
|
|
|||
|
|
@ -2,10 +2,10 @@
|
|||
|
||||
---
|
||||
|
||||
[How auto-redrawing-works](#how-auto-redrawing-works)
|
||||
[Integrating multiple execution threads](#integrating-multiple-execution-threads)
|
||||
[Integrating to legacy code](#integrating-to-legacy-code)
|
||||
[Signature](#signature)
|
||||
- [How auto-redrawing-works](#how-auto-redrawing-works)
|
||||
- [Integrating multiple execution threads](#integrating-multiple-execution-threads)
|
||||
- [Integrating to legacy code](#integrating-to-legacy-code)
|
||||
- [Signature](#signature)
|
||||
|
||||
---
|
||||
|
||||
|
|
|
|||
|
|
@ -2,12 +2,12 @@
|
|||
|
||||
---
|
||||
|
||||
[Usage](#usage)
|
||||
[Retrieving a value via the getter-setter API](#retrieving-a-value-via-the-getter-setter-api)
|
||||
[Integrating to the Mithril redrawing system](#integrating-to-the-mithril-redrawing-system)
|
||||
[Differences from Promises/A+](#differences-from-promises-a-)
|
||||
[The exception monitor](#the-exception-monitor)
|
||||
[Signature](#signature)
|
||||
- [Usage](#usage)
|
||||
- [Retrieving a value via the getter-setter API](#retrieving-a-value-via-the-getter-setter-api)
|
||||
- [Integrating to the Mithril redrawing system](#integrating-to-the-mithril-redrawing-system)
|
||||
- [Differences from Promises/A+](#differences-from-promises-a-)
|
||||
- [The exception monitor](#the-exception-monitor)
|
||||
- [Signature](#signature)
|
||||
|
||||
---
|
||||
|
||||
|
|
|
|||
|
|
@ -2,8 +2,8 @@
|
|||
|
||||
---
|
||||
|
||||
[Usage](#usage)
|
||||
[Signature](#signature)
|
||||
- [Usage](#usage)
|
||||
- [Signature](#signature)
|
||||
|
||||
---
|
||||
|
||||
|
|
|
|||
|
|
@ -2,16 +2,16 @@
|
|||
|
||||
---
|
||||
|
||||
[Usage](#usage)
|
||||
[Binding to data](#binding-to-data)
|
||||
[Using HTML entities](#using-html-entities)
|
||||
[Accessing the real DOM element](#accessing-the-real-dom-element)
|
||||
[Persisting config data](#persisting-config-data)
|
||||
[Destructors](#destructors)
|
||||
[SVG](#svg)
|
||||
[Dealing with focus](#dealing-with-focus)
|
||||
[Dealing with sorting and deleting in lists](#dealing-with-sorting-and-deleting-in-lists)
|
||||
[Signature](#signature)
|
||||
- [Usage](#usage)
|
||||
- [Binding to data](#binding-to-data)
|
||||
- [Using HTML entities](#using-html-entities)
|
||||
- [Accessing the real DOM element](#accessing-the-real-dom-element)
|
||||
- [Persisting config data](#persisting-config-data)
|
||||
- [Destructors](#destructors)
|
||||
- [SVG](#svg)
|
||||
- [Dealing with focus](#dealing-with-focus)
|
||||
- [Dealing with sorting and deleting in lists](#dealing-with-sorting-and-deleting-in-lists)
|
||||
- [Signature](#signature)
|
||||
|
||||
---
|
||||
|
||||
|
|
|
|||
|
|
@ -2,9 +2,9 @@
|
|||
|
||||
---
|
||||
|
||||
[Usage](#usage)
|
||||
[Unloading modules](#unloading-modules)
|
||||
[Signature](#signature)
|
||||
- [Usage](#usage)
|
||||
- [Unloading modules](#unloading-modules)
|
||||
- [Signature](#signature)
|
||||
|
||||
---
|
||||
|
||||
|
|
|
|||
|
|
@ -2,10 +2,10 @@
|
|||
|
||||
---
|
||||
|
||||
[Usage](#usage)
|
||||
[Third-party promise library support](#third-party-promise-library-support)
|
||||
[Serializing getter-setters](#serializing-getter-setters)
|
||||
[Signature](#signature)
|
||||
- [Usage](#usage)
|
||||
- [Third-party promise library support](#third-party-promise-library-support)
|
||||
- [Serializing getter-setters](#serializing-getter-setters)
|
||||
- [Signature](#signature)
|
||||
|
||||
---
|
||||
|
||||
|
|
|
|||
|
|
@ -2,10 +2,10 @@
|
|||
|
||||
---
|
||||
|
||||
[Changing redraw strategy](#changing-redraw-strategy)
|
||||
[Preventing redraws on events](#preventing-redraws-on-events)
|
||||
[Forcing redraw](#forcing-redraw)
|
||||
[Signature](#signature)
|
||||
- [Changing redraw strategy](#changing-redraw-strategy)
|
||||
- [Preventing redraws on events](#preventing-redraws-on-events)
|
||||
- [Forcing redraw](#forcing-redraw)
|
||||
- [Signature](#signature)
|
||||
|
||||
---
|
||||
|
||||
|
|
|
|||
|
|
@ -2,9 +2,9 @@
|
|||
|
||||
---
|
||||
|
||||
[Usage](#usage)
|
||||
[Subtree directives](#subtree directives)
|
||||
[Signature](#signature)
|
||||
- [Usage](#usage)
|
||||
- [Subtree directives](#subtree directives)
|
||||
- [Signature](#signature)
|
||||
|
||||
---
|
||||
|
||||
|
|
|
|||
|
|
@ -2,20 +2,20 @@
|
|||
|
||||
---
|
||||
|
||||
[Basic usage](#basic-usage)
|
||||
[Processing-web-service-data](#processing-web-service-data)
|
||||
[Bind redirection code](#bind-redirection-code)
|
||||
[Binding errors](#binding-errors)
|
||||
[Queuing operations](#queuing-operations)
|
||||
[Casting the Response Data to a Class](#casting-the-response-data-to-a-class)
|
||||
[Unwrapping Response Data](#unwrapping-response-data)
|
||||
[Using Different Data Transfer Formats](#using-different-data-transfer-formats)
|
||||
[Using variable data formats](#using-variable-data-formats)
|
||||
[Extracting Metadata from the Response](#extracting-metadata-from-the-response)
|
||||
[Custom request rejections](#custom-request-rejections)
|
||||
[Configuring the underlying XMLHttpRequest](#configuring-the-underlying-xmlhttprequest)
|
||||
[Aborting a request](#aborting-a-request)
|
||||
[Signature](#signature)
|
||||
- [Basic usage](#basic-usage)
|
||||
- [Processing-web-service-data](#processing-web-service-data)
|
||||
- [Bind redirection code](#bind-redirection-code)
|
||||
- [Binding errors](#binding-errors)
|
||||
- [Queuing operations](#queuing-operations)
|
||||
- [Casting the Response Data to a Class](#casting-the-response-data-to-a-class)
|
||||
- [Unwrapping Response Data](#unwrapping-response-data)
|
||||
- [Using Different Data Transfer Formats](#using-different-data-transfer-formats)
|
||||
- [Using variable data formats](#using-variable-data-formats)
|
||||
- [Extracting Metadata from the Response](#extracting-metadata-from-the-response)
|
||||
- [Custom request rejections](#custom-request-rejections)
|
||||
- [Configuring the underlying XMLHttpRequest](#configuring-the-underlying-xmlhttprequest)
|
||||
- [Aborting a request](#aborting-a-request)
|
||||
- [Signature](#signature)
|
||||
|
||||
---
|
||||
|
||||
|
|
|
|||
|
|
@ -2,13 +2,13 @@
|
|||
|
||||
---
|
||||
|
||||
[Defining routes](#defining-routes)
|
||||
[Variadic routes](#variadic-routes)
|
||||
[Routes with querystrings](#routes-with-querystrings)
|
||||
[Running clean up code on route change](#running-clean-up-code-on-route-change)
|
||||
[Redirecting](#redirecting)
|
||||
[Reading the currently active route](#reading-the-currently-active-route)
|
||||
[Mode abstraction](#mode abstraction)
|
||||
- [Defining routes](#defining-routes)
|
||||
- [Variadic routes](#variadic-routes)
|
||||
- [Routes with querystrings](#routes-with-querystrings)
|
||||
- [Running clean up code on route change](#running-clean-up-code-on-route-change)
|
||||
- [Redirecting](#redirecting)
|
||||
- [Reading the currently active route](#reading-the-currently-active-route)
|
||||
- [Mode abstraction](#mode abstraction)
|
||||
|
||||
---
|
||||
|
||||
|
|
|
|||
4
document.html
Normal file
4
document.html
Normal file
|
|
@ -0,0 +1,4 @@
|
|||
<script src="mithril.js"></script>
|
||||
<script type="text/javascript">
|
||||
m.render(document, m.trust("aa"))
|
||||
</script>
|
||||
Loading…
Add table
Add a link
Reference in a new issue