javascript-time-ago 2.6.1 → 2.6.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +2 -2
- package/bundle/javascript-time-ago.js.map +1 -1
- package/bundle/javascript-time-ago.min.js.map +1 -1
- package/commonjs/TimeAgo.js +8 -5
- package/commonjs/TimeAgo.js.map +1 -1
- package/index.d.ts +46 -7
- package/modules/TimeAgo.js +8 -5
- package/modules/TimeAgo.js.map +1 -1
- package/package.json +4 -4
- /package/{bin → scripts}/create-commonjs-package-json.js +0 -0
- /package/{bin → scripts}/generate-load-all-locales.js +0 -0
- /package/{bin → scripts}/generate-locale-messages.js +0 -0
package/README.md
CHANGED
|
@@ -492,7 +492,7 @@ import en from 'javascript-time-ago/locale/en'
|
|
|
492
492
|
// Steps from the built-in "round" style can be reused in custom styles.
|
|
493
493
|
import { round } from 'javascript-time-ago/steps'
|
|
494
494
|
|
|
495
|
-
TimeAgo.
|
|
495
|
+
TimeAgo.addLocale(en)
|
|
496
496
|
|
|
497
497
|
// Define custom labels.
|
|
498
498
|
const customLabels = {
|
|
@@ -1020,7 +1020,7 @@ To include this library directly via a `<script/>` tag on a page, one can use an
|
|
|
1020
1020
|
<script src="https://unpkg.com/javascript-time-ago@[version]/bundle/javascript-time-ago.js"></script>
|
|
1021
1021
|
|
|
1022
1022
|
<script>
|
|
1023
|
-
TimeAgo.
|
|
1023
|
+
TimeAgo.addLocale({
|
|
1024
1024
|
locale: 'en',
|
|
1025
1025
|
now: {
|
|
1026
1026
|
now: {
|