Commit 3dd7e46
committed
module: load JSON-LD with standard extension
The JSON-LD standard (http://www.w3.org/TR/json-ld/) requires sending
what is effectively JSON content using a different MIME type. Because
of that, it is usually required to use a file extension other than
.json since that is what is typically used in MIME type mapping in
HTTP servers. The IANA-registered file extension is .jsonld
(http://www.iana.org/assignments/media-types/application/ld+json).
This patch makes .jsonld documents loadable through require() in the
exact same manner that .json files are.1 parent aaf9b48 commit 3dd7e46
File tree
4 files changed
+23
-0
lines changed- lib
- test
- fixtures
- parallel
4 files changed
+23
-0
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
444 | 444 | | |
445 | 445 | | |
446 | 446 | | |
| 447 | + | |
| 448 | + | |
447 | 449 | | |
448 | 450 | | |
449 | 451 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
| 1 | + | |
| 2 | + | |
| 3 | + | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
| 1 | + | |
| 2 | + | |
| 3 | + | |
| 4 | + | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
| 1 | + | |
| 2 | + | |
| 3 | + | |
| 4 | + | |
| 5 | + | |
| 6 | + | |
| 7 | + | |
| 8 | + | |
| 9 | + | |
| 10 | + | |
| 11 | + | |
| 12 | + | |
| 13 | + | |
| 14 | + | |
0 commit comments