-
Notifications
You must be signed in to change notification settings - Fork 1
/
package.json
72 lines (72 loc) · 3.74 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
59
60
61
62
63
64
65
66
67
68
69
70
71
72
{
"name": "mimoza",
"version": "0.3.0",
"description": "Simple mime-types tools library",
"keywords": [
"mime"
],
"homepage": "https://github.com/nodeca/mimoza",
"author": {
"name": "Aleksey V Zapparov",
"email": "ixti@member.fsf.org",
"url": "http://ixti.net/"
},
"contributors": [
{
"name": "Vitaly Puzrin",
"email": "vitaly@rcdesign.ru",
"url": "https://github.com/puzrin"
},
{
"name": "Robert Kieffer",
"email": "robert@broofa.com",
"url": "https://github.com/broofa"
},
{
"name": "Benjamin Thomas",
"email": "benjamin@benjaminthomas.org",
"url": "https://github.com/bentomas"
}
],
"bugs": {
"url": "https://github.com/nodeca/mimoza/issues"
},
"license": {
"type": "MIT",
"url": "https://github.com/nodeca/mimoza/blob/master/LICENSE"
},
"repository": {
"type": "git",
"url": "git://github.com/nodeca/mimoza.git"
},
"main": "./lib/mimoza.js",
"devDependencies": {
"mocha": "*"
},
"browser": {
"./lib/rules.js": "./lib/rules_browser.js"
},
"readme": "# Mimoza\n\n[![Build Status](https://secure.travis-ci.org/nodeca/mimoza.png?branch=master)](http://travis-ci.org/nodeca/mimoza)\n\nMimoza is a tiny but comprehensive MIME tools library. Features:\n\n- Resolving mime type by file path/name/extention (with fallback\n for unknown cases).\n- Finding file extention by mime type.\n- Checking if mime type (or file) can be compressed.\n- Checking if mime type has text content (if you wish to force UTF-8 encoding)\n- You can have multimple instances with different configs.\n- Works in browser too (AMD module).\n\nSee detailed [API docs](http://nodeca.github.com/mimoza).\n\n## Installation\n\nfor node.js:\n\n```bash\nnpm install mimoza\n```\n\nfor browser (AMD module):\n\n```bash\nbower install mimoza\n```\n\n## Example\n\n``` javascript\nvar Mimoza = require('mimoza');\n\n// Use builtin methods:\n\nMimoza.getExtension('audio/ogg'); // -> '.oga'\n\nMimoza.getMimeType('ogg'); // -> 'audio/ogg'\nMimoza.getMimeType('.oga'); // -> 'audio/ogg'\nMimoza.getMimeType('test.oga'); // -> 'audio/ogg'\nMimoza.getMimeType('foo/bar.oga'); // -> 'audio/ogg'\n\nMimoza.isCompressible('text/html'); // -> true\nMimoza.isCompressible('application/octet-stream'); // -> false\n\nMimoza.isText('text/html'); // -> true\nMimoza.isText('application/javascript'); // -> true\nMimoza.isText('application/json'); // -> true\nMimoza.isText('application/octet-stream'); // -> false\n\n\n// Define your own instance\n\nvar mime = new Mimoza({\n defaultType: 'hard/core', // mime type for unknown extentions\n preloaded: true // load default rules\n});\n\n// instances are customizeable\nmime.register('foo/bar', ['baz', 'moo']);\n\nmime.getExtension('foo/bar'); // -> '.baz'\nmime.getMimeType('baz'); // -> 'foo/bar'\nmime.getMimeType('moo'); // -> 'foo/bar'\n\n// unknown file types, with default & custom fallback\nmime.getMimeType('tada'); // -> 'hard/core'\nmime.getMimeType('tada', 'soft/core'); // -> 'soft/core'\n```\n",
"readmeFilename": "README.md",
"_id": "mimoza@0.3.0",
"dist": {
"shasum": "007afccb4c8fcace652fa353d482c264ad70c1a6",
"tarball": "http://registry.npmjs.org/mimoza/-/mimoza-0.3.0.tgz"
},
"_from": "mimoza@~ 0.3.0",
"_resolved": "https://registry.npmjs.org/mimoza/-/mimoza-0.3.0.tgz",
"scripts": {},
"_npmVersion": "1.3.14",
"_npmUser": {
"name": "vitaly",
"email": "vitaly@rcdesign.ru"
},
"maintainers": [
{
"name": "vitaly",
"email": "vitaly@rcdesign.ru"
}
],
"directories": {},
"_shasum": "007afccb4c8fcace652fa353d482c264ad70c1a6"
}