UNPKG

1.39 kBJavaScriptView Raw
1'use strict';
2
3Object.defineProperty(exports, '__esModule', {
4 value: true
5});
6exports.default = void 0;
7
8/**
9 * Copyright (c) Facebook, Inc. and its affiliates. All Rights Reserved.
10 *
11 * This source code is licensed under the MIT license found in the
12 * LICENSE file in the root directory of this source tree.
13 */
14// This list is compiled after the MDN list of the most common MIME types (see
15// https://developer.mozilla.org/en-US/docs/Web/HTTP/Basics_of_HTTP/MIME_types/
16// Complete_list_of_MIME_types).
17//
18// Only MIME types starting with "image/", "video/", "audio/" and "font/" are
19// reflected in the list. Adding "application/" is too risky since some text
20// file formats (like ".js" and ".json") have an "application/" MIME type.
21//
22// Feel free to add any extensions that cannot be a Haste module.
23const extensions = new Set([
24 // JSONs are never haste modules, except for "package.json", which is handled.
25 '.json', // Image extensions.
26 '.bmp',
27 '.gif',
28 '.ico',
29 '.jpeg',
30 '.jpg',
31 '.png',
32 '.svg',
33 '.tiff',
34 '.tif',
35 '.webp', // Video extensions.
36 '.avi',
37 '.mp4',
38 '.mpeg',
39 '.mpg',
40 '.ogv',
41 '.webm',
42 '.3gp',
43 '.3g2', // Audio extensions.
44 '.aac',
45 '.midi',
46 '.mid',
47 '.mp3',
48 '.oga',
49 '.wav',
50 '.3gp',
51 '.3g2', // Font extensions.
52 '.eot',
53 '.otf',
54 '.ttf',
55 '.woff',
56 '.woff2'
57]);
58var _default = extensions;
59exports.default = _default;