Skip to content

Commit b0eeefd

Browse files
committed
docs(types): Consistently use JSDoc in comments for Adapter
1 parent 4185204 commit b0eeefd

2 files changed

Lines changed: 8 additions & 9 deletions

File tree

README.md

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -139,13 +139,13 @@ interface Adapter<Node, ElementNode extends Node> {
139139
*/
140140
getParent: (node: ElementNode) => ElementNode | null;
141141

142-
/*
143-
*Get the siblings of the node. Note that unlike jQuery's `siblings` method,
144-
*this is expected to include the current node as well
142+
/**
143+
* Get the siblings of the node. Note that unlike jQuery's `siblings` method,
144+
* this is expected to include the current node as well
145145
*/
146146
getSiblings: (node: Node) => Node[];
147147

148-
/*
148+
/**
149149
* Get the text content of the node, and its children if it has any.
150150
*/
151151
getText: (node: Node) => string;

src/types.ts

Lines changed: 4 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -34,13 +34,13 @@ export interface Adapter<Node, ElementNode extends Node> {
3434
*/
3535
getParent: (node: ElementNode) => ElementNode | null;
3636

37-
/*
38-
*Get the siblings of the node. Note that unlike jQuery's `siblings` method,
39-
*this is expected to include the current node as well
37+
/**
38+
* Get the siblings of the node. Note that unlike jQuery's `siblings` method,
39+
* this is expected to include the current node as well
4040
*/
4141
getSiblings: (node: Node) => Node[];
4242

43-
/*
43+
/**
4444
* Get the text content of the node, and its children if it has any.
4545
*/
4646
getText: (node: Node) => string;
@@ -95,7 +95,6 @@ export interface Adapter<Node, ElementNode extends Node> {
9595
isActive?: (elem: ElementNode) => boolean;
9696
}
9797

98-
// TODO default types to the domutils/htmlparser2 types
9998
export interface Options<Node, ElementNode extends Node> {
10099
/**
101100
* When enabled, tag names will be case-sensitive. Default: false.

0 commit comments

Comments
 (0)