From cf6b8be98cd6c533bcf1c007fcd65b58aabb8954 Mon Sep 17 00:00:00 2001 From: Justin Fagnani Date: Thu, 17 Feb 2022 18:25:00 -0800 Subject: [PATCH] Add `deprecated` to FunctionLike Also clean up a redundant `deprecated` that resulted from a bad rebase. --- schema.d.ts | 14 ++++++-------- schema.json | 15 +++++++++++++++ 2 files changed, 21 insertions(+), 8 deletions(-) diff --git a/schema.d.ts b/schema.d.ts index 8aad8b7..95e8c76 100644 --- a/schema.d.ts +++ b/schema.d.ts @@ -257,14 +257,6 @@ export interface CustomElement extends ClassLike { * custom element class */ customElement: true; - - // members?: Array; - - /** - * Whether the custom element is deprecated. - * If the value is a string, it's the reason for the deprecation. - */ - deprecated?: boolean | string; } export interface Attribute { @@ -695,6 +687,12 @@ export interface FunctionLike { */ description?: string; + /** + * Whether the function is deprecated. + * If the value is a string, it's the reason for the deprecation. + */ + deprecated?: boolean | string; + parameters?: Parameter[]; return?: { diff --git a/schema.json b/schema.json index f90b7ed..89a1456 100644 --- a/schema.json +++ b/schema.json @@ -155,6 +155,13 @@ }, "ClassMethod": { "properties": { + "deprecated": { + "description": "Whether the function is deprecated.\nIf the value is a string, it's the reason for the deprecation.", + "type": [ + "string", + "boolean" + ] + }, "description": { "description": "A markdown description.", "type": "string" @@ -597,6 +604,13 @@ }, "FunctionDeclaration": { "properties": { + "deprecated": { + "description": "Whether the function is deprecated.\nIf the value is a string, it's the reason for the deprecation.", + "type": [ + "string", + "boolean" + ] + }, "description": { "description": "A markdown description.", "type": "string" @@ -732,6 +746,7 @@ "type": "string" }, "path": { + "description": "Path to the javascript file needed to be imported. \n(not the path for example to a typescript file.)", "type": "string" }, "summary": {