Skip to content

Commit 7bf7f56

Browse files
committed
remove any
1 parent e904753 commit 7bf7f56

File tree

1 file changed

+4
-4
lines changed
  • packages/svelte/scripts/process-messages

1 file changed

+4
-4
lines changed

packages/svelte/scripts/process-messages/index.js

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -98,9 +98,7 @@ function run() {
9898
.readFileSync(new URL(`./templates/${name}.js`, import.meta.url), 'utf-8')
9999
.replace(/\r\n/g, '\n');
100100

101-
/**
102-
* @type {any[]}
103-
*/
101+
/** @type {import('acorn').Comment[]} */
104102
const comments = [];
105103

106104
let ast = acorn.parse(source, {
@@ -143,7 +141,9 @@ function run() {
143141
const template_node = ast.body[index];
144142
ast.body.splice(index, 1);
145143

146-
const jsdoc = comments.findLast((comment) => comment.start < template_node.start);
144+
const jsdoc = /** @type {import('acorn').Comment} */ (
145+
comments.findLast((comment) => comment.start < template_node.start)
146+
);
147147

148148
const printed = esrap.print(
149149
ast,

0 commit comments

Comments
 (0)