Skip to content

Commit 6cf9890

Browse files
committed
refactor: remove comment and extra variable
1 parent f2d5113 commit 6cf9890

File tree

1 file changed

+1
-3
lines changed

1 file changed

+1
-3
lines changed

packages/styled-react/src/__tests__/deprecated-exports.test.ts

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -24,12 +24,10 @@ for (const [, filepath, exports] of entrypoints) {
2424
ts.forEachChild(sourceFile!, node => {
2525
if (ts.isExportDeclaration(node) && node.exportClause && ts.isNamedExports(node.exportClause)) {
2626
for (const element of node.exportClause.elements) {
27-
const exportName = element.name.text
28-
// Check for JSDoc comments on the export specifier
2927
const jsDocTags = ts.getJSDocTags(element)
3028
const deprecatedTag = jsDocTags.find(tag => tag.tagName.text === 'deprecated')
3129

32-
exports.push([exportName, !!deprecatedTag, deprecatedTag ? deprecatedTag.comment !== undefined : false])
30+
exports.push([element.name.text, !!deprecatedTag, deprecatedTag ? deprecatedTag.comment !== undefined : false])
3331
}
3432
}
3533
})

0 commit comments

Comments
 (0)