aboutsummaryrefslogtreecommitdiff
path: root/docs/api/api-types.ts
diff options
context:
space:
mode:
authorShinigami <[email protected]>2022-08-22 23:38:15 +0800
committerGitHub <[email protected]>2022-08-22 17:38:15 +0200
commit0866ee9217e5e0b60e1c5f604e3576fb2604a3d5 (patch)
treeb54c310380b6892bacf5552d1dde4b325f00b09c /docs/api/api-types.ts
parentf684a14ddc3729c74f8434db68324269ae9a640f (diff)
downloadfaker-0866ee9217e5e0b60e1c5f604e3576fb2604a3d5.tar.xz
faker-0866ee9217e5e0b60e1c5f604e3576fb2604a3d5.zip
docs: searchable api (#1253)
Diffstat (limited to 'docs/api/api-types.ts')
-rw-r--r--docs/api/api-types.ts26
1 files changed, 26 insertions, 0 deletions
diff --git a/docs/api/api-types.ts b/docs/api/api-types.ts
new file mode 100644
index 00000000..f5dcd659
--- /dev/null
+++ b/docs/api/api-types.ts
@@ -0,0 +1,26 @@
+// These interfaces are copied over from https://github.com/vuejs/docs/blob/main/src/api/api.data.ts
+
+/**
+ * Represents a link to e.g. a Faker-Module method within the API search index page.
+ */
+export interface APIHeader {
+ anchor: string;
+ text: string;
+}
+
+/**
+ * Represents a container for e.g. a Faker-Module within the API search index page.
+ */
+export interface APIItem {
+ text: string;
+ link: string;
+ headers: APIHeader[];
+}
+
+/**
+ * Represents a whole section within the API search index page.
+ */
+export interface APIGroup {
+ text: string;
+ items: APIItem[];
+}