-
Notifications
You must be signed in to change notification settings - Fork 0
/
package.json
58 lines (58 loc) · 3.98 KB
/
package.json
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
{
"name": "dateformat",
"description": "A node.js package for Steven Levithan's excellent dateFormat() function.",
"maintainers": "Felix Geisendörfer <felix@debuggable.com>",
"homepage": "https://github.com/felixge/node-dateformat",
"author": {
"name": "Steven Levithan"
},
"contributors": [
{
"name": "Steven Levithan"
},
{
"name": "Felix Geisendörfer",
"email": "felix@debuggable.com"
},
{
"name": "Christoph Tavan",
"email": "dev@tavan.de"
}
],
"version": "1.0.11",
"licenses": {
"type": "MIT",
"url": "https://raw.githubusercontent.com/felixge/node-dateformat/master/LICENSE"
},
"main": "lib/dateformat",
"bin": {
"dateformat": "bin/cli.js"
},
"dependencies": {
"get-stdin": "*",
"meow": "*"
},
"devDependencies": {
"underscore": "1.7.0",
"mocha": "2.0.1"
},
"engines": {
"node": "*"
},
"scripts": {
"test": "mocha"
},
"repository": {
"type": "git",
"url": "https://github.com/felixge/node-dateformat.git"
},
"readme": "# dateformat\n\nA node.js package for Steven Levithan's excellent [dateFormat()][dateformat] function.\n\n[![Build Status](https://travis-ci.org/felixge/node-dateformat.svg)](https://travis-ci.org/felixge/node-dateformat)\n\n## Modifications\n\n* Removed the `Date.prototype.format` method. Sorry folks, but extending native prototypes is for suckers.\n* Added a `module.exports = dateFormat;` statement at the bottom\n* Added the placeholder `N` to get the ISO 8601 numeric representation of the day of the week\n\n## Installation\n\n```bash\n$ npm install dateformat\n$ dateformat --help\n```\n\n## Usage\n\nAs taken from Steven's post, modified to match the Modifications listed above:\n```js\n var dateFormat = require('dateformat');\n var now = new Date();\n\n // Basic usage\n dateFormat(now, \"dddd, mmmm dS, yyyy, h:MM:ss TT\");\n // Saturday, June 9th, 2007, 5:46:21 PM\n\n // You can use one of several named masks\n dateFormat(now, \"isoDateTime\");\n // 2007-06-09T17:46:21\n\n // ...Or add your own\n dateFormat.masks.hammerTime = 'HH:MM! \"Can\\'t touch this!\"';\n dateFormat(now, \"hammerTime\");\n // 17:46! Can't touch this!\n\n // When using the standalone dateFormat function,\n // you can also provide the date as a string\n dateFormat(\"Jun 9 2007\", \"fullDate\");\n // Saturday, June 9, 2007\n\n // Note that if you don't include the mask argument,\n // dateFormat.masks.default is used\n dateFormat(now);\n // Sat Jun 09 2007 17:46:21\n\n // And if you don't include the date argument,\n // the current date and time is used\n dateFormat();\n // Sat Jun 09 2007 17:46:22\n\n // You can also skip the date argument (as long as your mask doesn't\n // contain any numbers), in which case the current date/time is used\n dateFormat(\"longTime\");\n // 5:46:22 PM EST\n\n // And finally, you can convert local time to UTC time. Simply pass in\n // true as an additional argument (no argument skipping allowed in this case):\n dateFormat(now, \"longTime\", true);\n // 10:46:21 PM UTC\n\n // ...Or add the prefix \"UTC:\" or \"GMT:\" to your mask.\n dateFormat(now, \"UTC:h:MM:ss TT Z\");\n // 10:46:21 PM UTC\n\n // You can also get the ISO 8601 week of the year:\n dateFormat(now, \"W\");\n // 42\n\n // and also get the ISO 8601 numeric representation of the day of the week:\n dateFormat(now,\"N\");\n // 6\n```\n## License\n\n(c) 2007-2009 Steven Levithan [stevenlevithan.com][stevenlevithan], MIT license.\n\n[dateformat]: http://blog.stevenlevithan.com/archives/date-time-format\n[stevenlevithan]: http://stevenlevithan.com/\n",
"readmeFilename": "Readme.md",
"bugs": {
"url": "https://github.com/felixge/node-dateformat/issues"
},
"_id": "dateformat@1.0.11",
"_shasum": "f27cbee7a012bbfb82ea051562d3977f6093dbb1",
"_resolved": "https://registry.npmjs.org/dateformat/-/dateformat-1.0.11.tgz",
"_from": "dateformat@>=1.0.6 <1.1.0"
}