aboutsummaryrefslogtreecommitdiff
path: root/scripts/apidoc/directMethods.ts
diff options
context:
space:
mode:
authorShinigami <[email protected]>2022-08-14 01:59:21 +0800
committerGitHub <[email protected]>2022-08-13 19:59:21 +0200
commitfda44bb899efbcbac2071a199964a3e269cbd805 (patch)
tree5d40c4f4ab9968f5dee45164455431fb8de1e1b5 /scripts/apidoc/directMethods.ts
parenteb9c5c2c04934a20e801850a73b4ee2b41101f7c (diff)
downloadfaker-fda44bb899efbcbac2071a199964a3e269cbd805.tar.xz
faker-fda44bb899efbcbac2071a199964a3e269cbd805.zip
docs: rewrite api pages to have a right aside toc (#1265)
Diffstat (limited to 'scripts/apidoc/directMethods.ts')
-rw-r--r--scripts/apidoc/directMethods.ts8
1 files changed, 4 insertions, 4 deletions
diff --git a/scripts/apidoc/directMethods.ts b/scripts/apidoc/directMethods.ts
index 159ad848..fbdd094e 100644
--- a/scripts/apidoc/directMethods.ts
+++ b/scripts/apidoc/directMethods.ts
@@ -37,21 +37,21 @@ export function processDirectMethod(
direct: TypeDoc.DeclarationReflection
): Page {
const methodName = direct.name;
- const upperMethodName =
+ const capitalizedMethodName =
methodName.substring(0, 1).toUpperCase() + methodName.substring(1);
- console.log(`Processing Direct: ${upperMethodName}`);
+ console.log(`Processing Direct: ${capitalizedMethodName}`);
const signatures = (direct.type as TypeDoc.ReflectionType).declaration
.signatures;
const signature = signatures[signatures.length - 1];
- writeApiDocsDirectPage(methodName);
+ writeApiDocsDirectPage(methodName, capitalizedMethodName);
writeApiDocsData(methodName, [
analyzeSignature(signature, undefined, methodName),
]);
return {
- text: upperMethodName,
+ text: capitalizedMethodName,
link: `/api/${methodName}.html`,
};
}