compressible
Advanced tools
Comparing version 1.0.1 to 1.1.0
@@ -21,3 +21,2 @@ module.exports = compressible | ||
compressible: false, | ||
sources: [], | ||
notes: "Invalid type." | ||
@@ -32,2 +31,2 @@ } | ||
} | ||
} | ||
} |
{ | ||
"name": "compressible", | ||
"description": "Compressible Content-Type / mime checking", | ||
"version": "1.0.1", | ||
"version": "1.1.0", | ||
"author": { | ||
@@ -33,11 +33,7 @@ "name": "Jonathan Ong", | ||
"devDependencies": { | ||
"mocha": "*", | ||
"benchmark": "*", | ||
"beautify-benchmark": "~0.2.4", | ||
"mime": "*" | ||
"mocha": "~1.20.1" | ||
}, | ||
"scripts": { | ||
"test": "mocha --reporter spec test/compressible.js", | ||
"posttest": "mocha --reporter spec test/benchmarks.js" | ||
"test": "mocha --reporter spec test/" | ||
} | ||
} |
@@ -1,5 +0,12 @@ | ||
# Compressible [![Build Status](https://travis-ci.org/expressjs/compressible.png)](https://travis-ci.org/expressjs/compressible) | ||
# compressible | ||
[![Build Status](https://travis-ci.org/expressjs/compressible.svg?branch=master)](https://travis-ci.org/expressjs/compressible) | ||
[![NPM Version](https://badge.fury.io/js/compressible.svg)](https://badge.fury.io/js/compressible) | ||
Compressible `Content-Type` / `mime` checking. | ||
```sh | ||
$ npm install compressible | ||
``` | ||
## API | ||
@@ -11,4 +18,4 @@ | ||
var compressible = require('compressible') | ||
compressible('text/html') // -> true | ||
compressible('image/png') // -> false | ||
compressible('text/html') // => true | ||
compressible('image/png') // => false | ||
``` | ||
@@ -52,2 +59,2 @@ | ||
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN | ||
THE SOFTWARE. | ||
THE SOFTWARE. |
@@ -6,64 +6,39 @@ { | ||
"http://en.wikipedia.org/wiki/Atom_(standard)" | ||
], | ||
"notes": "" | ||
] | ||
}, | ||
"application/dart": { | ||
"compressible": true, | ||
"sources": [], | ||
"notes": "" | ||
"compressible": true | ||
}, | ||
"application/EDI-X12": { | ||
"compressible": false, | ||
"sources": [], | ||
"notes": "" | ||
"compressible": false | ||
}, | ||
"application/EDIFACT": { | ||
"compressible": false, | ||
"sources": [], | ||
"notes": "" | ||
"compressible": false | ||
}, | ||
"application/ecmascript": { | ||
"compressible": true, | ||
"sources": [], | ||
"notes": "" | ||
"compressible": true | ||
}, | ||
"application/font-woff": { | ||
"compressible": false, | ||
"sources": [], | ||
"notes": "" | ||
"compressible": false | ||
}, | ||
"application/gzip": { | ||
"compressible": false, | ||
"sources": [], | ||
"notes": "" | ||
"compressible": false | ||
}, | ||
"application/java-archive": { | ||
"compressible": false, | ||
"sources": [], | ||
"notes": "" | ||
"compressible": false | ||
}, | ||
"application/java-serialized-object": { | ||
"compressible": false, | ||
"sources": [], | ||
"notes": "" | ||
"compressible": false | ||
}, | ||
"application/java-vm": { | ||
"compressible": false, | ||
"sources": [], | ||
"notes": "" | ||
"compressible": false | ||
}, | ||
"application/javascript": { | ||
"compressible": true, | ||
"sources": [], | ||
"notes": "" | ||
"compressible": true | ||
}, | ||
"application/json": { | ||
"compressible": true, | ||
"sources": [], | ||
"notes": "" | ||
"compressible": true | ||
}, | ||
"application/msword": { | ||
"compressible": false, | ||
"sources": [], | ||
"notes": "" | ||
"compressible": false | ||
}, | ||
@@ -74,24 +49,15 @@ "application/octet-stream": { | ||
"https://github.com/broofa/node-mime/blob/master/types/mime.types#L154" | ||
], | ||
"notes": "" | ||
] | ||
}, | ||
"application/ogg": { | ||
"compressible": false, | ||
"sources": [], | ||
"notes": "" | ||
"compressible": false | ||
}, | ||
"application/pdf": { | ||
"compressible": false, | ||
"sources": [], | ||
"notes": "" | ||
"compressible": false | ||
}, | ||
"application/pgp-encrypted": { | ||
"compressible": false, | ||
"sources": [], | ||
"notes": "" | ||
"compressible": false | ||
}, | ||
"application/postscript": { | ||
"compressible": true, | ||
"sources": [], | ||
"notes": "" | ||
"compressible": true | ||
}, | ||
@@ -102,14 +68,9 @@ "application/rdf+xml": { | ||
"http://en.wikipedia.org/wiki/RDF/XML" | ||
], | ||
"notes": "" | ||
] | ||
}, | ||
"application/rss+xml": { | ||
"compressible": true, | ||
"sources": [], | ||
"notes": "" | ||
"compressible": true | ||
}, | ||
"application/rtf": { | ||
"compressible": true, | ||
"sources": [], | ||
"notes": "" | ||
"compressible": true | ||
}, | ||
@@ -120,19 +81,12 @@ "application/soap+xml": { | ||
"http://en.wikipedia.org/wiki/SOAP" | ||
], | ||
"notes": "" | ||
] | ||
}, | ||
"application/tar": { | ||
"compressible": true, | ||
"sources": [], | ||
"notes": "" | ||
"compressible": true | ||
}, | ||
"application/vnd.android.package-archive": { | ||
"compressible": false, | ||
"sources": [], | ||
"notes": "" | ||
"compressible": false | ||
}, | ||
"application/vnd.dart": { | ||
"compressible": true, | ||
"sources": [], | ||
"notes": "" | ||
"compressible": true | ||
}, | ||
@@ -143,9 +97,6 @@ "application/vnd.google-earth.kml+xml": { | ||
"https://developers.google.com/kml/documentation/kml_tut" | ||
], | ||
"notes": "" | ||
] | ||
}, | ||
"application/vnd.google-earth.kmz": { | ||
"compressible": false, | ||
"sources": [], | ||
"notes": "" | ||
"compressible": false | ||
}, | ||
@@ -156,9 +107,6 @@ "application/vnd.mozilla.xul+xml": { | ||
"http://en.wikipedia.org/wiki/XUL" | ||
], | ||
"notes": "" | ||
] | ||
}, | ||
"application/vnd.ms-excel": { | ||
"compressible": false, | ||
"sources": [], | ||
"notes": "" | ||
"compressible": false | ||
}, | ||
@@ -169,4 +117,3 @@ "application/vnd.ms-fontobject": { | ||
"http://www.phpied.com/gzip-your-font-face-files/" | ||
], | ||
"notes": "" | ||
] | ||
}, | ||
@@ -177,29 +124,18 @@ "application/vnd.ms-opentype": { | ||
"http://www.phpied.com/gzip-your-font-face-files/" | ||
], | ||
"notes": "" | ||
] | ||
}, | ||
"application/vnd.ms-powerpoint": { | ||
"compressible": false, | ||
"sources": [], | ||
"notes": "" | ||
"compressible": false | ||
}, | ||
"application/vnd.ms-xpsdocument": { | ||
"compressible": false, | ||
"sources": [], | ||
"notes": "" | ||
"compressible": false | ||
}, | ||
"application/vnd.oasis.opendocument.graphics": { | ||
"compressible": false, | ||
"sources": [], | ||
"notes": "" | ||
"compressible": false | ||
}, | ||
"application/vnd.oasis.opendocument.presentation": { | ||
"compressible": false, | ||
"sources": [], | ||
"notes": "" | ||
"compressible": false | ||
}, | ||
"application/vnd.oasis.opendocument.spreadsheet": { | ||
"compressible": false, | ||
"sources": [], | ||
"notes": "" | ||
"compressible": false | ||
}, | ||
@@ -210,44 +146,27 @@ "application/vnd.oasis.opendocument.text": { | ||
"http://en.wikipedia.org/wiki/OpenDocument_technical_specification#File_types" | ||
], | ||
"notes": "" | ||
] | ||
}, | ||
"application/vnd.openxmlformats-officedocument.presentationml.presentation": { | ||
"compressible": false, | ||
"sources": [], | ||
"notes": "" | ||
"compressible": false | ||
}, | ||
"application/vnd.openxmlformats-officedocument.spreadsheetml.sheet": { | ||
"compressible": false, | ||
"sources": [], | ||
"notes": "" | ||
"compressible": false | ||
}, | ||
"application/vnd.openxmlformats-officedocument.wordprocessingml.document": { | ||
"compressible": false, | ||
"sources": [], | ||
"notes": "" | ||
"compressible": false | ||
}, | ||
"application/x-7z-compressed": { | ||
"compressible": false, | ||
"sources": [], | ||
"notes": "" | ||
"compressible": false | ||
}, | ||
"application/x-bzip": { | ||
"compressible": false, | ||
"sources": [], | ||
"notes": "" | ||
"compressible": false | ||
}, | ||
"application/x-bzip2": { | ||
"compressible": false, | ||
"sources": [], | ||
"notes": "" | ||
"compressible": false | ||
}, | ||
"application/x-deb": { | ||
"compressible": false, | ||
"sources": [], | ||
"notes": "" | ||
"compressible": false | ||
}, | ||
"application/x-dvi": { | ||
"compressible": false, | ||
"sources": [], | ||
"notes": "" | ||
"compressible": false | ||
}, | ||
@@ -258,4 +177,3 @@ "application/x-font-otf": { | ||
"http://www.phpied.com/gzip-your-font-face-files/" | ||
], | ||
"notes": "" | ||
] | ||
}, | ||
@@ -266,74 +184,45 @@ "application/x-font-ttf": { | ||
"http://www.phpied.com/gzip-your-font-face-files/" | ||
], | ||
"notes": "" | ||
] | ||
}, | ||
"application/x-java-jnlp-file": { | ||
"compressible": false, | ||
"sources": [], | ||
"notes": "" | ||
"compressible": false | ||
}, | ||
"application/x-javascript": { | ||
"compressible": true, | ||
"sources": [], | ||
"notes": "" | ||
"compressible": true | ||
}, | ||
"application/x-latex": { | ||
"compressible": false, | ||
"sources": [], | ||
"notes": "" | ||
"compressible": false | ||
}, | ||
"application/x-mpegURL": { | ||
"compressible": false, | ||
"sources": [], | ||
"notes": "" | ||
"compressible": false | ||
}, | ||
"application/x-pkcs12": { | ||
"compressible": false, | ||
"sources": [], | ||
"notes": "" | ||
"compressible": false | ||
}, | ||
"application/x-rar-compressed": { | ||
"compressible": false, | ||
"sources": [], | ||
"notes": "" | ||
"compressible": false | ||
}, | ||
"application/x-sh": { | ||
"compressible": true, | ||
"sources": [], | ||
"notes": "" | ||
"compressible": true | ||
}, | ||
"application/x-shockwave-flash": { | ||
"compressible": false, | ||
"sources": [], | ||
"notes": "" | ||
"compressible": false | ||
}, | ||
"application/x-stuffit": { | ||
"compressible": false, | ||
"sources": [], | ||
"notes": "" | ||
"compressible": false | ||
}, | ||
"application/x-tar": { | ||
"compressible": true, | ||
"sources": [], | ||
"notes": "" | ||
"compressible": true | ||
}, | ||
"application/x-www-form-urlencode": { | ||
"compressible": false, | ||
"sources": [], | ||
"notes": "" | ||
"compressible": false | ||
}, | ||
"application/x-xpinstall": { | ||
"compressible": false, | ||
"sources": [], | ||
"notes": "" | ||
"compressible": false | ||
}, | ||
"application/xhtml+xml": { | ||
"compressible": true, | ||
"sources": [], | ||
"notes": "" | ||
"compressible": true | ||
}, | ||
"application/xml": { | ||
"compressible": true, | ||
"sources": [], | ||
"notes": "" | ||
"compressible": true | ||
}, | ||
@@ -344,69 +233,42 @@ "application/xml-dtd": { | ||
"http://en.wikipedia.org/wiki/Document_type_definition" | ||
], | ||
"notes": "" | ||
] | ||
}, | ||
"application/xop+xml": { | ||
"compressible": true, | ||
"sources": [], | ||
"notes": "" | ||
"compressible": true | ||
}, | ||
"application/zip": { | ||
"compressible": false, | ||
"sources": [], | ||
"notes": "" | ||
"compressible": false | ||
}, | ||
"audio/L24": { | ||
"compressible": false, | ||
"sources": [], | ||
"notes": "" | ||
"compressible": false | ||
}, | ||
"audio/basic": { | ||
"compressible": false, | ||
"sources": [], | ||
"notes": "" | ||
"compressible": false | ||
}, | ||
"audio/mp4": { | ||
"compressible": false, | ||
"sources": [], | ||
"notes": "" | ||
"compressible": false | ||
}, | ||
"audio/mpeg": { | ||
"compressible": false, | ||
"sources": [], | ||
"notes": "" | ||
"compressible": false | ||
}, | ||
"audio/ogg": { | ||
"compressible": false, | ||
"sources": [], | ||
"notes": "" | ||
"compressible": false | ||
}, | ||
"audio/vnd.rn-realaudio": { | ||
"compressible": false, | ||
"sources": [], | ||
"notes": "" | ||
"compressible": false | ||
}, | ||
"audio/vnd.wave": { | ||
"compressible": false, | ||
"sources": [], | ||
"notes": "" | ||
"compressible": false | ||
}, | ||
"audio/vorbis": { | ||
"compressible": false, | ||
"sources": [], | ||
"notes": "" | ||
"compressible": false | ||
}, | ||
"audio/webm": { | ||
"compressible": false, | ||
"sources": [], | ||
"notes": "" | ||
"compressible": false | ||
}, | ||
"audio/x-aac": { | ||
"compressible": false, | ||
"sources": [], | ||
"notes": "" | ||
"compressible": false | ||
}, | ||
"audio/x-caf": { | ||
"compressible": false, | ||
"sources": [], | ||
"notes": "" | ||
"compressible": false | ||
}, | ||
@@ -417,4 +279,3 @@ "font/opentype": { | ||
"http://www.phpied.com/gzip-your-font-face-files/" | ||
], | ||
"notes": "" | ||
] | ||
}, | ||
@@ -425,29 +286,18 @@ "image/bmp": { | ||
"http://stackoverflow.com/a/12770116" | ||
], | ||
"notes": "" | ||
] | ||
}, | ||
"image/gif": { | ||
"compressible": false, | ||
"sources": [], | ||
"notes": "" | ||
"compressible": false | ||
}, | ||
"image/jpeg": { | ||
"compressible": false, | ||
"sources": [], | ||
"notes": "" | ||
"compressible": false | ||
}, | ||
"image/pjpeg": { | ||
"compressible": false, | ||
"sources": [], | ||
"notes": "" | ||
"compressible": false | ||
}, | ||
"image/png": { | ||
"compressible": false, | ||
"sources": [], | ||
"notes": "" | ||
"compressible": false | ||
}, | ||
"image/svg+xml": { | ||
"compressible": true, | ||
"sources": [], | ||
"notes": "" | ||
"compressible": true | ||
}, | ||
@@ -462,5 +312,3 @@ "image/tiff": { | ||
"image/vnd.adobe.photoshop": { | ||
"compressible": true, | ||
"sources": [], | ||
"notes": "" | ||
"compressible": true | ||
}, | ||
@@ -475,5 +323,3 @@ "image/x-icon": { | ||
"image/x-xcf": { | ||
"compressible": false, | ||
"sources": [], | ||
"notes": "" | ||
"compressible": false | ||
}, | ||
@@ -491,9 +337,6 @@ "message/http": { | ||
"http://tools.ietf.org/html/rfc5438" | ||
], | ||
"notes": "" | ||
] | ||
}, | ||
"message/partial": { | ||
"compressible": false, | ||
"sources": [], | ||
"notes": "" | ||
"compressible": false | ||
}, | ||
@@ -504,34 +347,21 @@ "message/rfc822": { | ||
"http://en.wikipedia.org/wiki/MIME#Multipart_subtypes" | ||
], | ||
"notes": "" | ||
] | ||
}, | ||
"model/example": { | ||
"compressible": false, | ||
"sources": [], | ||
"notes": "" | ||
"compressible": false | ||
}, | ||
"model/iges": { | ||
"compressible": false, | ||
"sources": [], | ||
"notes": "" | ||
"compressible": false | ||
}, | ||
"model/mesh": { | ||
"compressible": false, | ||
"sources": [], | ||
"notes": "" | ||
"compressible": false | ||
}, | ||
"model/vrml": { | ||
"compressible": false, | ||
"sources": [], | ||
"notes": "" | ||
"compressible": false | ||
}, | ||
"model/x3d+binary": { | ||
"compressible": false, | ||
"sources": [], | ||
"notes": "" | ||
"compressible": false | ||
}, | ||
"model/x3d+vrml": { | ||
"compressible": false, | ||
"sources": [], | ||
"notes": "" | ||
"compressible": false | ||
}, | ||
@@ -542,34 +372,21 @@ "model/x3d+xml": { | ||
"http://edutechwiki.unige.ch/en/X3D_file_structure" | ||
], | ||
"notes": "" | ||
] | ||
}, | ||
"multipart/alternative": { | ||
"compressible": false, | ||
"sources": [], | ||
"notes": "" | ||
"compressible": false | ||
}, | ||
"multipart/encrypted": { | ||
"compressible": false, | ||
"sources": [], | ||
"notes": "" | ||
"compressible": false | ||
}, | ||
"multipart/form-data": { | ||
"compressible": false, | ||
"sources": [], | ||
"notes": "" | ||
"compressible": false | ||
}, | ||
"multipart/mixed": { | ||
"compressible": false, | ||
"sources": [], | ||
"notes": "" | ||
"compressible": false | ||
}, | ||
"multipart/related": { | ||
"compressible": false, | ||
"sources": [], | ||
"notes": "" | ||
"compressible": false | ||
}, | ||
"multipart/signed": { | ||
"compressible": false, | ||
"sources": [], | ||
"notes": "" | ||
"compressible": false | ||
}, | ||
@@ -588,28 +405,18 @@ "text/cache-manifest": { | ||
], | ||
"notes": "Probably needs to be uncompressed before sent to iCalender, though." | ||
"notes": "Probably needs to be uncompressed before sent to iCalender." | ||
}, | ||
"text/cmd": { | ||
"compressible": true, | ||
"sources": [], | ||
"notes": "" | ||
"compressible": true | ||
}, | ||
"text/css": { | ||
"compressible": true, | ||
"sources": [], | ||
"notes": "" | ||
"compressible": true | ||
}, | ||
"text/csv": { | ||
"compressible": true, | ||
"sources": [], | ||
"notes": "" | ||
"compressible": true | ||
}, | ||
"text/html": { | ||
"compressible": true, | ||
"sources": [], | ||
"notes": "" | ||
"compressible": true | ||
}, | ||
"text/javascript": { | ||
"compressible": true, | ||
"sources": [], | ||
"notes": "" | ||
"compressible": true | ||
}, | ||
@@ -620,89 +427,54 @@ "text/n3": { | ||
"http://en.wikipedia.org/wiki/Notation3" | ||
], | ||
"notes": "" | ||
] | ||
}, | ||
"text/plain": { | ||
"compressible": true, | ||
"sources": [], | ||
"notes": "" | ||
"compressible": true | ||
}, | ||
"text/richtext": { | ||
"compressible": true, | ||
"sources": [], | ||
"notes": "" | ||
"compressible": true | ||
}, | ||
"text/tab-separated-values": { | ||
"compressible": true, | ||
"sources": [], | ||
"notes": "" | ||
"compressible": true | ||
}, | ||
"text/uri-list": { | ||
"compressible": true, | ||
"sources": [], | ||
"notes": "" | ||
"compressible": true | ||
}, | ||
"text/vcard": { | ||
"compressible": true, | ||
"sources": [], | ||
"notes": "" | ||
"compressible": true | ||
}, | ||
"text/x-gwt-rpc": { | ||
"compressible": true, | ||
"sources": [], | ||
"notes": "" | ||
"compressible": true | ||
}, | ||
"text/x-jquery-tmpl": { | ||
"compressible": true, | ||
"sources": [], | ||
"notes": "" | ||
"compressible": true | ||
}, | ||
"text/x-markdown": { | ||
"compressible": true, | ||
"sources": [], | ||
"notes": "" | ||
"compressible": true | ||
}, | ||
"text/xml": { | ||
"compressible": true, | ||
"sources": [], | ||
"notes": "" | ||
"compressible": true | ||
}, | ||
"video/mp4": { | ||
"compressible": false, | ||
"sources": [], | ||
"notes": "" | ||
"compressible": false | ||
}, | ||
"video/mpeg": { | ||
"compressible": false, | ||
"sources": [], | ||
"notes": "" | ||
"compressible": false | ||
}, | ||
"video/ogg": { | ||
"compressible": false, | ||
"sources": [], | ||
"notes": "" | ||
"compressible": false | ||
}, | ||
"video/quicktime": { | ||
"compressible": false, | ||
"sources": [], | ||
"notes": "" | ||
"compressible": false | ||
}, | ||
"video/webm": { | ||
"compressible": false, | ||
"sources": [], | ||
"notes": "" | ||
"compressible": false | ||
}, | ||
"video/x-flv": { | ||
"compressible": false, | ||
"sources": [], | ||
"notes": "" | ||
"compressible": false | ||
}, | ||
"video/x-matroska": { | ||
"compressible": false, | ||
"sources": [], | ||
"notes": "" | ||
"compressible": false | ||
}, | ||
"video/x-ms-wmv": { | ||
"compressible": false, | ||
"sources": [], | ||
"notes": "" | ||
"compressible": false | ||
}, | ||
@@ -712,6 +484,12 @@ "x-shader/x-fragment": { | ||
"sources": [ | ||
"https://developer.mozilla.org/en-US/docs/Web/WebGL/Adding_2D_content_to_a_WebGL_context", | ||
"https://bugzilla.mozilla.org/show_bug.cgi?id=715191#c2" | ||
], | ||
"notes": "" | ||
] | ||
}, | ||
"x-shader/x-vertex": { | ||
"compressible": true, | ||
"sources": [ | ||
"https://developer.mozilla.org/en-US/docs/Web/WebGL/Adding_2D_content_to_a_WebGL_context" | ||
] | ||
} | ||
} | ||
} |
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
1
59
13745
5
498