reffy 5.0.0 → 5.2.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +2 -0
- package/package.json +9 -9
- package/reffy.js +0 -0
- package/src/cli/parse-webidl.js +1 -3
- package/src/lib/nock-server.js +3 -3
- package/src/lib/util.js +2 -2
package/README.md
CHANGED
|
@@ -1,5 +1,7 @@
|
|
|
1
1
|
# Reffy
|
|
2
2
|
|
|
3
|
+
<img align="right" width="256" height="256" src="images/reffy-512.png" alt="Reffy, represented as a brave little worm with a construction helmet, ready to crawl specs">
|
|
4
|
+
|
|
3
5
|
Reffy is a **Web spec crawler** tool. It is notably used to update [Webref](https://github.com/w3c/webref#webref) every 6 hours.
|
|
4
6
|
|
|
5
7
|
The code features a generic crawler that can fetch Web specifications and generate machine-readable extracts out of them. Created extracts include lists of CSS properties, definitions, IDL, links and references contained in the specification.
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "reffy",
|
|
3
|
-
"version": "5.
|
|
3
|
+
"version": "5.2.2",
|
|
4
4
|
"description": "W3C/WHATWG spec dependencies exploration companion. Features a short set of tools to study spec references as well as WebIDL term definitions and references found in W3C specifications.",
|
|
5
5
|
"repository": {
|
|
6
6
|
"type": "git",
|
|
@@ -32,20 +32,20 @@
|
|
|
32
32
|
"bin": "./reffy.js",
|
|
33
33
|
"dependencies": {
|
|
34
34
|
"abortcontroller-polyfill": "1.7.3",
|
|
35
|
-
"browser-specs": "2.
|
|
36
|
-
"commander": "8.
|
|
35
|
+
"browser-specs": "2.20.0",
|
|
36
|
+
"commander": "8.3.0",
|
|
37
37
|
"fetch-filecache-for-crawling": "4.0.2",
|
|
38
|
-
"puppeteer": "
|
|
38
|
+
"puppeteer": "13.0.1",
|
|
39
39
|
"semver": "^7.3.5",
|
|
40
|
-
"webidl2": "24.
|
|
40
|
+
"webidl2": "24.2.0"
|
|
41
41
|
},
|
|
42
42
|
"devDependencies": {
|
|
43
43
|
"chai": "4.3.4",
|
|
44
|
-
"mocha": "9.1.
|
|
45
|
-
"nock": "13.1
|
|
46
|
-
"respec": "
|
|
44
|
+
"mocha": "9.1.3",
|
|
45
|
+
"nock": "13.2.1",
|
|
46
|
+
"respec": "28.1.0",
|
|
47
47
|
"respec-hljs": "2.1.1",
|
|
48
|
-
"rollup": "2.
|
|
48
|
+
"rollup": "2.61.1"
|
|
49
49
|
},
|
|
50
50
|
"scripts": {
|
|
51
51
|
"test": "mocha --recursive tests/"
|
package/reffy.js
CHANGED
|
File without changes
|
package/src/cli/parse-webidl.js
CHANGED
|
@@ -350,9 +350,7 @@ function parseType(idltype, idlReport, contextName) {
|
|
|
350
350
|
return;
|
|
351
351
|
}
|
|
352
352
|
var wellKnownTypes = ["undefined", "any", "boolean", "byte", "octet", "short", "unsigned short", "long", "unsigned long", "long long", "unsigned long long", "float", "unrestricted float", "double", "unrestricted double", "DOMString", "ByteString", "USVString", "object",
|
|
353
|
-
"RegExp", "Error", "DOMException"
|
|
354
|
-
"BigUint64Array", "BigInt64Array",
|
|
355
|
-
"ArrayBufferView", "BufferSource", "DOMTimeStamp", "Function", "VoidFunction"];
|
|
353
|
+
"RegExp", "Error", "DOMException"];
|
|
356
354
|
if (wellKnownTypes.indexOf(idltype.idlType) === -1) {
|
|
357
355
|
addDependency(idltype.idlType, idlReport.idlNames, idlReport.externalDependencies);
|
|
358
356
|
if (contextName) {
|
package/src/lib/nock-server.js
CHANGED
|
@@ -74,9 +74,9 @@ nock("https://api.specref.org")
|
|
|
74
74
|
|
|
75
75
|
nock("https://www.w3.org")
|
|
76
76
|
.persist()
|
|
77
|
-
.get("/scripts/TR/
|
|
78
|
-
.get("/StyleSheets/TR/
|
|
79
|
-
.get("/StyleSheets/TR/
|
|
77
|
+
.get("/scripts/TR/2021/fixup.js").reply(200, '')
|
|
78
|
+
.get("/StyleSheets/TR/2021/logos/W3C").reply(200, '')
|
|
79
|
+
.get("/StyleSheets/TR/2021/base.css").reply(200, '')
|
|
80
80
|
.get("/Tools/respec/respec-highlight").replyWithFile(200, path.join(modulesFolder, "respec-hljs", "dist", "respec-highlight.js"), {"Content-Type": "application/js"})
|
|
81
81
|
.get("/Tools/respec/respec-w3c").replyWithFile(200, path.join(modulesFolder, "respec", "builds", "respec-w3c.js"), {"Content-Type": "application/js"});
|
|
82
82
|
|
package/src/lib/util.js
CHANGED
|
@@ -525,8 +525,8 @@ async function processSpecification(spec, processFunction, args, options) {
|
|
|
525
525
|
if (counter > 60) {
|
|
526
526
|
throw new Error('Respec generation took too long');
|
|
527
527
|
}
|
|
528
|
-
if (window.document.
|
|
529
|
-
await window.document.
|
|
528
|
+
if (window.document.respec?.ready) {
|
|
529
|
+
await window.document.respec.ready;
|
|
530
530
|
}
|
|
531
531
|
else if (usesRespec) {
|
|
532
532
|
await sleep(1000);
|