Skip to content

Commit b196e8f

Browse files
committed
regenned docs
1 parent 3672f9a commit b196e8f

44 files changed

Lines changed: 49 additions & 47 deletions

Some content is hidden

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

best/actions.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -44,7 +44,7 @@
4444
<body>
4545

4646

47-
<div class="book" data-level="7.3" data-basepath=".." data-revision="Wed Jun 21 2017 09:35:51 GMT+0200 (CEST)">
47+
<div class="book" data-level="7.3" data-basepath=".." data-revision="Mon Jul 10 2017 21:26:48 GMT+0200 (CEST)">
4848

4949

5050
<div class="book-summary">

best/decorators.html

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -44,7 +44,7 @@
4444
<body>
4545

4646

47-
<div class="book" data-level="5" data-basepath=".." data-revision="Wed Jun 21 2017 09:35:51 GMT+0200 (CEST)">
47+
<div class="book" data-level="5" data-basepath=".." data-revision="Mon Jul 10 2017 21:26:48 GMT+0200 (CEST)">
4848

4949

5050
<div class="book-summary">
@@ -897,7 +897,7 @@ <h1>
897897
<h2 id="enabling-decorators">Enabling decorators</h2>
898898
<p>If you want to use decorators follow the following steps.</p>
899899
<p><strong>TypeScript</strong></p>
900-
<p>Enable the compiler option <code>experimentalDecorators</code> in <code>tsconfig.json</code> or pass it as flag <code>--experimentalDecorators</code> to the compiler.</p>
900+
<p>Enable the compiler option <code>experimentalDecorators</code> in <code>tsconfig.json</code> or pass it as flag <code>--experimentalDecorators</code> to the compiler. You must target <code>es5</code>+ (es5, es6, ...) with <code>target</code> option or by <code>--target</code> flag.</p>
901901
<p><strong>Babel:</strong></p>
902902
<p>Install support for decorators: <code>npm i --save-dev babel-plugin-transform-decorators-legacy</code>. And enable it in your <code>.babelrc</code> file:</p>
903903
<pre><code>{
@@ -915,6 +915,7 @@ <h2 id="enabling-decorators">Enabling decorators</h2>
915915
}
916916
</code></pre><h2 id="limitations-on-decorators">Limitations on decorators</h2>
917917
<ul>
918+
<li>typescript target must be es5 minimum</li>
918919
<li>reflect-metadata <a href="https://github.com/mobxjs/mobx/issues/534" target="_blank">https://github.com/mobxjs/mobx/issues/534</a></li>
919920
<li>decorators are not supported out of the box in <code>create-react-app</code>. To fix this, you can either eject, or use <a href="https://www.npmjs.com/package/custom-react-scripts" target="_blank">custom-react-scripts</a> for <code>create-react-app</code> (<a href="https://medium.com/@kitze/configure-create-react-app-without-ejecting-d8450e96196a#.n6xx12p5c" target="_blank">blog</a>)</li>
920921
<li><del>decorators are currently not yet support in Next.JS <a href="https://github.com/zeit/next.js/issues/26" target="_blank">issue</a></del> Decorators are now supported in Next.JS. Example: <a href="https://github.com/zeit/next.js/tree/master/examples/with-mobx" target="_blank">https://github.com/zeit/next.js/tree/master/examples/with-mobx</a></li>

best/devtools.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -44,7 +44,7 @@
4444
<body>
4545

4646

47-
<div class="book" data-level="7.5" data-basepath=".." data-revision="Wed Jun 21 2017 09:35:51 GMT+0200 (CEST)">
47+
<div class="book" data-level="7.5" data-basepath=".." data-revision="Mon Jul 10 2017 21:26:48 GMT+0200 (CEST)">
4848

4949

5050
<div class="book-summary">

best/pitfalls.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -44,7 +44,7 @@
4444
<body>
4545

4646

47-
<div class="book" data-level="7.1" data-basepath=".." data-revision="Wed Jun 21 2017 09:35:51 GMT+0200 (CEST)">
47+
<div class="book" data-level="7.1" data-basepath=".." data-revision="Mon Jul 10 2017 21:26:48 GMT+0200 (CEST)">
4848

4949

5050
<div class="book-summary">

best/react-performance.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -44,7 +44,7 @@
4444
<body>
4545

4646

47-
<div class="book" data-level="7.4" data-basepath=".." data-revision="Wed Jun 21 2017 09:35:51 GMT+0200 (CEST)">
47+
<div class="book" data-level="7.4" data-basepath=".." data-revision="Mon Jul 10 2017 21:26:48 GMT+0200 (CEST)">
4848

4949

5050
<div class="book-summary">

best/react.html

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -44,7 +44,7 @@
4444
<body>
4545

4646

47-
<div class="book" data-level="4" data-basepath=".." data-revision="Wed Jun 21 2017 09:35:51 GMT+0200 (CEST)">
47+
<div class="book" data-level="4" data-basepath=".." data-revision="Mon Jul 10 2017 21:26:48 GMT+0200 (CEST)">
4848

4949

5050
<div class="book-summary">
@@ -1029,9 +1029,9 @@ <h4 id="incorrect-using-not-yet-existing-observable-object-properties">Incorrect
10291029
<p>This will <strong>not</strong> react. MobX will not react to observable properties that did not exist when tracking started.
10301030
If the two statements are swapped, or if any other observable causes the <code>autorun</code> to re-run, the <code>autorun</code> will start tracking the <code>postDate</code> as well.</p>
10311031
<h4 id="correct-using-not-yet-existing-map-entries">Correct: using not yet existing map entries</h4>
1032-
<pre><code class="lang-javascript"><span class="hljs-keyword">const</span> twitterUrls = observable(asMap({
1032+
<pre><code class="lang-javascript"><span class="hljs-keyword">const</span> twitterUrls = observable.map({
10331033
<span class="hljs-string">&quot;John&quot;</span>: <span class="hljs-string">&quot;twitter.com/johnny&quot;</span>
1034-
}))
1034+
})
10351035

10361036
autorun(() =&gt; {
10371037
<span class="hljs-built_in">console</span>.log(twitterUrls.get(<span class="hljs-string">&quot;Sara&quot;</span>))

best/stateless-HMR.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -44,7 +44,7 @@
4444
<body>
4545

4646

47-
<div class="book" data-level="7.7" data-basepath=".." data-revision="Wed Jun 21 2017 09:35:51 GMT+0200 (CEST)">
47+
<div class="book" data-level="7.7" data-basepath=".." data-revision="Mon Jul 10 2017 21:26:48 GMT+0200 (CEST)">
4848

4949

5050
<div class="book-summary">

best/store.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -44,7 +44,7 @@
4444
<body>
4545

4646

47-
<div class="book" data-level="7.2" data-basepath=".." data-revision="Wed Jun 21 2017 09:35:51 GMT+0200 (CEST)">
47+
<div class="book" data-level="7.2" data-basepath=".." data-revision="Mon Jul 10 2017 21:26:48 GMT+0200 (CEST)">
4848

4949

5050
<div class="book-summary">

best/syntax.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -44,7 +44,7 @@
4444
<body>
4545

4646

47-
<div class="book" data-level="7.6" data-basepath=".." data-revision="Wed Jun 21 2017 09:35:51 GMT+0200 (CEST)">
47+
<div class="book" data-level="7.6" data-basepath=".." data-revision="Mon Jul 10 2017 21:26:48 GMT+0200 (CEST)">
4848

4949

5050
<div class="book-summary">

donating.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,7 @@
4242
<body>
4343

4444

45-
<div class="book" data-level="9" data-basepath="." data-revision="Wed Jun 21 2017 09:35:51 GMT+0200 (CEST)">
45+
<div class="book" data-level="9" data-basepath="." data-revision="Mon Jul 10 2017 21:26:48 GMT+0200 (CEST)">
4646

4747

4848
<div class="book-summary">

0 commit comments

Comments
 (0)