Travis build: 316
This commit is contained in:
13
README.md
13
README.md
@ -81,6 +81,7 @@
|
|||||||
* [`getDaysDiffBetweenDates`](#getdaysdiffbetweendates)
|
* [`getDaysDiffBetweenDates`](#getdaysdiffbetweendates)
|
||||||
* [`JSONToDate`](#jsontodate)
|
* [`JSONToDate`](#jsontodate)
|
||||||
* [`toEnglishDate`](#toenglishdate)
|
* [`toEnglishDate`](#toenglishdate)
|
||||||
|
* [`tomorrow`](#tomorrow)
|
||||||
|
|
||||||
### Function
|
### Function
|
||||||
* [`chainAsync`](#chainasync)
|
* [`chainAsync`](#chainasync)
|
||||||
@ -1152,6 +1153,18 @@ const toEnglishDate = (time) =>
|
|||||||
// toEnglishDate('09/21/2010') -> '21/09/2010'
|
// toEnglishDate('09/21/2010') -> '21/09/2010'
|
||||||
```
|
```
|
||||||
|
|
||||||
|
[⬆ back to top](#table-of-contents)
|
||||||
|
|
||||||
|
### tomorrow
|
||||||
|
|
||||||
|
Results in a string representation of tomorrow's date.
|
||||||
|
Use `new Date()` to get today's date, adding `86400000` of seconds to it(24 hours), using `toISOString` to convert Date object to string.
|
||||||
|
|
||||||
|
```js
|
||||||
|
const tomorrow = () => new Date(new Date() + 86400000).toISOString().split('T')[0];
|
||||||
|
// tomorrow() -> 2017-12-26
|
||||||
|
```
|
||||||
|
|
||||||
[⬆ back to top](#table-of-contents)
|
[⬆ back to top](#table-of-contents)
|
||||||
## Function
|
## Function
|
||||||
|
|
||||||
|
|||||||
@ -142,6 +142,7 @@
|
|||||||
</h3><a class="sublink-1" href="#getdaysdiffbetweendates">getDaysDiffBetweenDates</a>
|
</h3><a class="sublink-1" href="#getdaysdiffbetweendates">getDaysDiffBetweenDates</a>
|
||||||
<a class="sublink-1" href="#jsontodate">JSONToDate</a>
|
<a class="sublink-1" href="#jsontodate">JSONToDate</a>
|
||||||
<a class="sublink-1" href="#toenglishdate">toEnglishDate</a>
|
<a class="sublink-1" href="#toenglishdate">toEnglishDate</a>
|
||||||
|
<a class="sublink-1" href="#tomorrow">tomorrow</a>
|
||||||
|
|
||||||
<h3>Function
|
<h3>Function
|
||||||
</h3><a class="sublink-1" href="#chainasync">chainAsync</a>
|
</h3><a class="sublink-1" href="#chainasync">chainAsync</a>
|
||||||
@ -784,6 +785,12 @@ Throws an error if the passed time cannot be converted to a date.</p>
|
|||||||
{try{return new Date(time).toISOString().split('T')[0].replace(/-/g, '/')}catch(e){return}};
|
{try{return new Date(time).toISOString().split('T')[0].replace(/-/g, '/')}catch(e){return}};
|
||||||
// toEnglishDate('09/21/2010') -> '21/09/2010'
|
// toEnglishDate('09/21/2010') -> '21/09/2010'
|
||||||
</code></pre>
|
</code></pre>
|
||||||
|
</div></div><br/><div class="card fluid"><div class="section double-padded"><h3 id="tomorrow">tomorrow</h3></div><div class="section double-padded">
|
||||||
|
<p>Results in a string representation of tomorrow's date.
|
||||||
|
Use <code>new Date()</code> to get today's date, adding <code>86400000</code> of seconds to it(24 hours), using <code>toISOString</code> to convert Date object to string.</p>
|
||||||
|
<pre><code class="language-js">const tomorrow = () => new Date(new Date() + 86400000).toISOString().split('T')[0];
|
||||||
|
// tomorrow() -> 2017-12-26
|
||||||
|
</code></pre>
|
||||||
</div></div><br/><h2 style="text-align:center">Function</h2>
|
</div></div><br/><h2 style="text-align:center">Function</h2>
|
||||||
<div class="card fluid"><div class="section double-padded"><h3 id="chainasync">chainAsync</h3></div><div class="section double-padded">
|
<div class="card fluid"><div class="section double-padded"><h3 id="chainasync">chainAsync</h3></div><div class="section double-padded">
|
||||||
<p>Chains asynchronous functions.</p>
|
<p>Chains asynchronous functions.</p>
|
||||||
|
|||||||
Reference in New Issue
Block a user