chrono-node 1.4.3 → 1.4.4
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 +3 -29
- package/dist/chrono.js +7865 -0
- package/dist/chrono.js.map +1 -0
- package/dist/chrono.min.js +3 -0
- package/dist/chrono.min.js.LICENSE.txt +19 -0
- package/dist/chrono.min.js.map +1 -0
- package/package.json +9 -7
- package/src/parsers/en/ENSlashMonthFormatParser.js +2 -3
- package/test/en/en_month.test.js +43 -0
- package/webpack.config.js +39 -0
- package/bower.json +0 -24
- package/chrono.js +0 -8101
- package/chrono.map.json +0 -1
- package/chrono.min.js +0 -163
- package/chrono.min.json +0 -1
- package/karma.conf.js +0 -68
- package/timezone.js +0 -9
package/README.md
CHANGED
|
@@ -15,9 +15,7 @@ Chrono supports most date and time formats, such as :
|
|
|
15
15
|
* Sat Aug 17 2013 18:40:39 GMT+0900 (JST)
|
|
16
16
|
* 2014-11-30T08:15:30-05:30
|
|
17
17
|
|
|
18
|
-
##
|
|
19
|
-
|
|
20
|
-
#### npm (recommended)
|
|
18
|
+
## Installation
|
|
21
19
|
|
|
22
20
|
Just run:
|
|
23
21
|
```bash
|
|
@@ -30,22 +28,6 @@ var chrono = require('chrono-node');
|
|
|
30
28
|
chrono.parseDate('An appointment on Sep 12-13');
|
|
31
29
|
```
|
|
32
30
|
|
|
33
|
-
#### Bower
|
|
34
|
-
|
|
35
|
-
Prefer bower? You can do that, too:
|
|
36
|
-
|
|
37
|
-
Just run:
|
|
38
|
-
```bash
|
|
39
|
-
$ bower install chrono
|
|
40
|
-
```
|
|
41
|
-
And use:
|
|
42
|
-
|
|
43
|
-
```html
|
|
44
|
-
<script src="bower_components/chrono/chrono.min.js"></script>
|
|
45
|
-
<script>chrono.parseDate('An appointment on Sep 12-13')</script>
|
|
46
|
-
```
|
|
47
|
-
|
|
48
|
-
|
|
49
31
|
#### Other Options:
|
|
50
32
|
|
|
51
33
|
Doing something else? No worries. Try these:
|
|
@@ -60,14 +42,6 @@ Swift | Try using the community-made [chrono-swift] wrapper.
|
|
|
60
42
|
[jsDelivr]: https://www.jsdelivr.com/projects/chrono
|
|
61
43
|
[chrono-swift]: https://github.com/neilsardesai/chrono-swift
|
|
62
44
|
|
|
63
|
-
#### Browserify
|
|
64
|
-
|
|
65
|
-
Chrono's modules are linked and packaged using [Browserify](http://browserify.org) on `src/chrono.js`. By default, `chrono.js` file exports `chrono` object as a window global.
|
|
66
|
-
|
|
67
|
-
```bash
|
|
68
|
-
$ browserify src/chrono.js --s chrono -o chrono.js
|
|
69
|
-
```
|
|
70
|
-
|
|
71
45
|
## Usage
|
|
72
46
|
|
|
73
47
|
Simply pass a string to function `chrono.parseDate` or `chrono.parse`.
|
|
@@ -314,9 +288,9 @@ $ npm run test
|
|
|
314
288
|
$ npm run watch
|
|
315
289
|
```
|
|
316
290
|
|
|
317
|
-
Chrono's source files is in `src` directory. The built bundle (`
|
|
291
|
+
Chrono's source files is in `src` directory. The built bundle (`dist/*`) is created by running [Webpack](https://webpack.js.org/) via the following command
|
|
318
292
|
|
|
319
293
|
```bash
|
|
320
|
-
$ npm run
|
|
294
|
+
$ npm run build
|
|
321
295
|
```
|
|
322
296
|
|