Skip to content

Commit

Permalink
chore: remove validation for ts api docs
Browse files Browse the repository at this point in the history
  • Loading branch information
Dhaiwat10 committed Oct 24, 2024
1 parent c4afe42 commit c86279b
Showing 1 changed file with 0 additions and 39 deletions.
39 changes: 0 additions & 39 deletions scripts/generate-links/processVPConfig.mjs
Original file line number Diff line number Diff line change
@@ -1,20 +1,4 @@
import { EOL } from 'os';

import { getFile } from './getFile.mjs';

const tsAPIOrderFile = getFile(
'./fuels-ts/apps/docs/.typedoc/api-links.json',
'default',
true
);
const nightlyTsAPIOrderFile = getFile(
'./fuels-ts/apps/docs/.typedoc/api-links.json',
'nightly',
true
);

function extractData(inputString) {
// used for api.json order
const regex = /"([^"]+)":\s*"([^"]+)"/g;
const match = regex.exec(inputString);
if (match !== null) {
Expand Down Expand Up @@ -79,29 +63,6 @@ function handleVPLine(
newVPOrder.menu.push(linkName);
}
}
} else if (trimmedLine.startsWith('apiLinks')) {
// handle API order
newVPOrder.menu.push('API');
let apiJSON;
if (isNightly) {
apiJSON = nightlyTsAPIOrderFile;
} else {
apiJSON = tsAPIOrderFile;
}
const apiLines = JSON.stringify(apiJSON, null, 2).split(EOL);
apiLines.forEach((apiLine, apiIndex) => {
const trimmedAPILine = apiLine.trimStart();
const results = handleVPLine(
trimmedAPILine,
apiLines,
apiIndex,
newVPOrder,
category,
isNightly
);
category = results.category;
newVPOrder = results.newVPOrder;
});
}

return { newVPOrder, category };
Expand Down

0 comments on commit c86279b

Please sign in to comment.