Skip to content

Commit 2142640

Browse files
Tried with puppeteer
1 parent 8c78ccb commit 2142640

File tree

2 files changed

+16
-2
lines changed

2 files changed

+16
-2
lines changed

common/script/specLinks.mjs

Lines changed: 12 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,3 @@
1-
2-
31
import fs from "fs";
42
import path from "path";
53
import { execSync } from "child_process";
@@ -60,9 +58,21 @@ function buildAllSpecs() {
6058
}
6159
}
6260

61+
// Helper: Install npm dependencies
62+
function installDependencies() {
63+
try {
64+
console.log("Installing npm dependencies...");
65+
execSync("npm install", { stdio: "inherit", cwd: process.cwd() });
66+
} catch (e) {
67+
console.error("Failed to install dependencies:", e.message);
68+
throw e;
69+
}
70+
}
71+
6372
// Main orchestrator
6473
async function main() {
6574
try {
75+
installDependencies();
6676
rewriteRootEDLinks();
6777
rewriteSubdirEDLinks();
6878
buildAllSpecs();

package.json

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,10 @@
33
"version": "1.0.0",
44
"description": "This repository maintains specifications and related publications for the Accessible Rich Internet Applications suite of technologies. This is developed by the [ARIA Working Group](http://www.w3.org/WAI/about/groups/ariawg). The W3C staff contact is Daniel Montalvo. Please do not provide commit access to this repository without coordination.",
55
"main": "index.js",
6+
"dependencies": {
7+
"respec": "^34.4.0",
8+
"puppeteer": "^21.11.0"
9+
},
610
"devDependencies": {},
711
"scripts": {
812
"test": "echo \"Error: no test specified\" && exit 1",

0 commit comments

Comments
 (0)