File tree Expand file tree Collapse file tree 4 files changed +7
-7
lines changed
Expand file tree Collapse file tree 4 files changed +7
-7
lines changed Original file line number Diff line number Diff line change @@ -5,9 +5,9 @@ import { parseApiDoc } from './utils/parse.mjs';
55/**
66 * This generator generates a flattened list of metadata entries from a API doc
77 *
8- * @typedef {ParserOutput<import('mdast').Root>[] } Input
8+ * @typedef {Array< ParserOutput<import('mdast').Root>> } Input
99 *
10- * @type {GeneratorMetadata<Input, ApiDocMetadataEntry[] > }
10+ * @type {GeneratorMetadata<Input, Array< ApiDocMetadataEntry> > }
1111 */
1212export default {
1313 name : 'metadata' ,
@@ -20,7 +20,7 @@ export default {
2020
2121 /**
2222 * @param {Input } inputs
23- * @returns {Promise<ApiDocMetadataEntry[] > }
23+ * @returns {Promise<Array< ApiDocMetadataEntry> > }
2424 */
2525 async generate ( inputs ) {
2626 return inputs . flatMap ( input => parseApiDoc ( input ) ) ;
Original file line number Diff line number Diff line change @@ -15,7 +15,7 @@ import createMetadata from '../../../metadata.mjs';
1515 * This generator generates a flattened list of metadata entries from a API doc
1616 *
1717 * @param {ParserOutput<import('mdast').Root> } input
18- * @returns {Promise<ApiDocMetadataEntry[] > }
18+ * @returns {Promise<Array< ApiDocMetadataEntry> > }
1919 */
2020export const parseApiDoc = ( { file, tree } ) => {
2121 /**
Original file line number Diff line number Diff line change @@ -15,8 +15,8 @@ const createLoader = () => {
1515 /**
1616 * Loads API Doc files and transforms it into VFiles
1717 *
18- * @param {string[] } searchPath A glob/path for API docs to be loaded
19- * @param {string[] | undefined } ignorePath A glob/path of files to ignore
18+ * @param {Array< string> } searchPath A glob/path for API docs to be loaded
19+ * @param {Array< string> | undefined } [ ignorePath] A glob/path of files to ignore
2020 * The input string can be a simple path (relative or absolute)
2121 * The input string can also be any allowed glob string
2222 *
Original file line number Diff line number Diff line change @@ -47,7 +47,7 @@ const createParser = linter => {
4747 * and it simply wraps parseApiDoc with the given API docs
4848 *
4949 * @param {Array<import('vfile').VFile | Promise<import('vfile').VFile>> } apiDocs List of API doc files to be parsed
50- * @returns {Promise<ParserOutput<import('mdast').Root>[] > }
50+ * @returns {Promise<Array< ParserOutput<import('mdast').Root>> > }
5151 */
5252 const parseApiDocs = async apiDocs => {
5353 // We do a Promise.all, to ensure that each API doc is resolved asynchronously
You can’t perform that action at this time.
0 commit comments