@microsoft/api-extractor
Version:
Validatation, documentation, and auditing for the exported API of a TypeScript package
363 lines (362 loc) • 10.1 kB
JSON
{
"kind": "package",
"summary": [
{
"kind": "textDocElement",
"value": "This example folder is used to test the functionality of DocItemLoader and API reference resolution."
}
],
"remarks": [],
"exports": {
"inheritEnumValues": {
"kind": "enum",
"values": {
"index_one": {
"kind": "enum value",
"value": "1",
"deprecatedMessage": [],
"summary": [
{
"kind": "textDocElement",
"value": "We will also try to inherit this."
}
],
"remarks": [],
"isBeta": false
},
"index_zero": {
"kind": "enum value",
"value": "0",
"deprecatedMessage": [],
"summary": [
{
"kind": "textDocElement",
"value": "This is documentation that we will try to inherit."
}
],
"remarks": [],
"isBeta": false
}
},
"deprecatedMessage": [],
"summary": [
{
"kind": "textDocElement",
"value": "We will try to inherit the documentation for the enum's values."
}
],
"remarks": [],
"isBeta": false
},
"inheritLocalCircularDependencyOne": {
"kind": "enum",
"values": {},
"deprecatedMessage": [],
"summary": [],
"remarks": [],
"isBeta": false
},
"inheritLocalCircularDependencyTwo": {
"kind": "enum",
"values": {},
"deprecatedMessage": [],
"summary": [],
"remarks": [],
"isBeta": false
},
"inheritLocalOptionOne": {
"kind": "enum",
"values": {},
"deprecatedMessage": [],
"summary": [
{
"kind": "textDocElement",
"value": "This is the summary for MyClass."
}
],
"remarks": [],
"isBeta": false
},
"inheritLocalOptionTwoFunction": {
"kind": "function",
"returnValue": {
"type": "void",
"description": []
},
"parameters": {},
"deprecatedMessage": [],
"summary": [
{
"kind": "textDocElement",
"value": "See documentation for MyClass.methodWithTwoParams"
}
],
"remarks": [],
"isBeta": false
},
"IStructuredTypeInherit": {
"kind": "interface",
"extends": "",
"implements": "",
"typeParameters": [],
"deprecatedMessage": [],
"summary": [
{
"kind": "textDocElement",
"value": "This is a summary on the interface API item."
}
],
"remarks": [],
"isBeta": false,
"members": {
"thisIsTypeLiteral": {
"kind": "property",
"isOptional": false,
"isReadOnly": false,
"isStatic": false,
"type": "[{name: string, age: number}]",
"deprecatedMessage": [],
"summary": [
{
"kind": "textDocElement",
"value": "This is the summary on an API item that is a type literal."
}
],
"remarks": [],
"isBeta": false
}
}
},
"IStructuredTypeSource": {
"kind": "interface",
"extends": "",
"implements": "",
"typeParameters": [],
"deprecatedMessage": [],
"summary": [
{
"kind": "textDocElement",
"value": "This is a summary on the interface API item."
}
],
"remarks": [],
"isBeta": false,
"members": {
"thisIsTypeLiteral": {
"kind": "property",
"isOptional": false,
"isReadOnly": false,
"isStatic": false,
"type": "{\r\n [ key: string ]: string;\r\n renderingArea: string;\r\n }",
"deprecatedMessage": [],
"summary": [
{
"kind": "textDocElement",
"value": "This is the summary on an API item that is a type literal."
}
],
"remarks": [],
"isBeta": false
}
}
},
"jsonResolutionClass": {
"kind": "class",
"extends": "",
"implements": "",
"typeParameters": [],
"deprecatedMessage": [],
"summary": [
{
"kind": "textDocElement",
"value": "For a library such as \"example-package\", ApiFileGenerator generates the \"example-package.api.ts\" report which is used to detect API changes. The output is pseudocode whose syntax is similar but not identical to a \"*.d.ts\" typings file. The output file is designed to be committed to Git with a branch policy that will trigger an API review workflow whenever the file contents have changed. For example, the API file indicates *whether* a class has been documented, but it does not include the documentation text (since minor text changes should not require an API review)."
}
],
"remarks": [],
"isBeta": false,
"members": {
"jsonResolutionMethod": {
"kind": "method",
"signature": "public jsonResolutionMethod(): boolean;",
"accessModifier": "public",
"isOptional": false,
"isStatic": false,
"returnValue": {
"type": "boolean",
"description": [
{
"kind": "textDocElement",
"value": "A description for the return value, even though it's void."
}
]
},
"parameters": {
"param1": {
"name": "param1",
"description": [
{
"kind": "textDocElement",
"value": "A description for param1."
}
],
"isOptional": false,
"isSpread": false,
"type": "string"
}
},
"deprecatedMessage": [],
"summary": [
{
"kind": "textDocElement",
"value": "A summary message for forEach()."
}
],
"remarks": [
{
"kind": "textDocElement",
"value": "A remarks message for forEach()."
}
],
"isBeta": false
}
}
},
"jsonResolutionFunction": {
"kind": "function",
"returnValue": {
"type": "boolean",
"description": [
{
"kind": "textDocElement",
"value": "A description for the return value, even though it's void."
}
]
},
"parameters": {
"param1": {
"name": "param1",
"description": [
{
"kind": "textDocElement",
"value": "A description for param1."
}
],
"isOptional": false,
"isSpread": false,
"type": "string"
}
},
"deprecatedMessage": [],
"summary": [
{
"kind": "textDocElement",
"value": "A summary message for forEach()."
}
],
"remarks": [
{
"kind": "textDocElement",
"value": "A remarks message for forEach()."
}
],
"isBeta": false
},
"MyClass": {
"kind": "class",
"extends": "",
"implements": "",
"typeParameters": [],
"deprecatedMessage": [],
"summary": [
{
"kind": "textDocElement",
"value": "This is the summary for MyClass."
}
],
"remarks": [],
"isBeta": false
},
"publicEnum": {
"kind": "enum",
"values": {},
"deprecatedMessage": [],
"summary": [
{
"kind": "textDocElement",
"value": "This enum is public and any API items can safely inherit documentation or link to this item."
}
],
"remarks": [],
"isBeta": false
},
"sourceEnumValuesDoc": {
"kind": "enum",
"values": {
"one": {
"kind": "enum value",
"value": "1",
"deprecatedMessage": [],
"summary": [
{
"kind": "textDocElement",
"value": "We will also try to inherit this."
}
],
"remarks": [],
"isBeta": false
},
"zero": {
"kind": "enum value",
"value": "0",
"deprecatedMessage": [],
"summary": [
{
"kind": "textDocElement",
"value": "This is documentation that we will try to inherit."
}
],
"remarks": [],
"isBeta": false
}
},
"deprecatedMessage": [],
"summary": [
{
"kind": "textDocElement",
"value": "We will try to inheritdoc the documentation for one of the enum value's documentation."
}
],
"remarks": [],
"isBeta": false
},
"testingLinks": {
"kind": "enum",
"values": {},
"deprecatedMessage": [],
"summary": [
{
"kind": "textDocElement",
"value": "Here we test that an error is reported when attempting to link to an internal API item."
},
{
"kind": "linkDocElement",
"referenceType": "code",
"scopeName": "",
"packageName": "",
"exportName": "publicEnum",
"memberName": ""
},
{
"kind": "linkDocElement",
"referenceType": "code",
"scopeName": "",
"packageName": "",
"exportName": "internalEnum",
"memberName": ""
}
],
"remarks": [],
"isBeta": false
}
}
}