Skip to content

Commit

Permalink
fix: ensure no closing comments in JSDoc (#221)
Browse files Browse the repository at this point in the history
  • Loading branch information
OliverDudgeon authored Oct 7, 2021
1 parent e0631d3 commit eb6cbd3
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion src/utils/doc.ts
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,9 @@ export function jsDoc(
},
tryOneLine = false,
): string {
const lines = Array.isArray(description) ? description : [description];
// Ensure there aren't any comment terminations in doc
const lines = (Array.isArray(description) ? description : [description])
.map(line => line.replace('*/', '*\\/'));

const count = [description, deprecated, summary].reduce(
(acc, it) => (it ? acc + 1 : acc),
Expand Down

1 comment on commit eb6cbd3

@vercel
Copy link

@vercel vercel bot commented on eb6cbd3 Oct 7, 2021

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please sign in to comment.