Clean js plugins (#18839)
This commit is contained in:
1 parent
5f88a9314f
commit
91625a1220
3 files changed
+6
-8
No files matched your search
+2
-2
@@ -2,7 +2,7 @@ import { addLeadingComment } from "../../../main/comments/utilities.js";
|
||||
import { locStart } from "../../loc.js";
|
||||
import { stripComments } from "../../utilities/strip-comments.js";
|
||||
|
||||
function handleForXComments({
|
||||
function handleForXStatementComments({
|
||||
comment,
|
||||
enclosingNode,
|
||||
followingNode,
|
||||
@@ -29,4 +29,4 @@ function handleForXComments({
|
||||
return false;
|
||||
}
|
||||
|
||||
export { handleForXComments };
|
||||
export { handleForXStatementComments };
|
||||
@@ -29,7 +29,7 @@ import {
|
||||
isUnionType,
|
||||
} from "../utilities/node-types.js";
|
||||
import { stripComments } from "../utilities/strip-comments.js";
|
||||
import { handleForXComments } from "./attach/handle-for-x-statement.js";
|
||||
import { handleForXStatementComments } from "./attach/handle-for-x-statement-comments.js";
|
||||
import { handleIfStatementComments } from "./attach/handle-if-statement-comments.js";
|
||||
import { handleWhileLikeComments } from "./attach/handle-while-like-comments.js";
|
||||
import {
|
||||
@@ -71,7 +71,7 @@ function handleOwnLineComment(context) {
|
||||
handleWhileLikeComments,
|
||||
handleTryStatementComments,
|
||||
handleClassComments,
|
||||
handleForXComments,
|
||||
handleForXStatementComments,
|
||||
handleUnionTypeComments,
|
||||
handleMatchOrPatternComments,
|
||||
handleOnlyComments,
|
||||
@@ -101,7 +101,7 @@ function handleEndOfLineComment(context) {
|
||||
handleWhileLikeComments,
|
||||
handleTryStatementComments,
|
||||
handleClassComments,
|
||||
handleForXComments,
|
||||
handleForXStatementComments,
|
||||
handleLabeledStatementComments,
|
||||
handleCallExpressionComments,
|
||||
handlePropertyComments,
|
||||
@@ -127,7 +127,7 @@ function handleRemainingComment(context) {
|
||||
handleIgnoreComments,
|
||||
handleIfStatementComments,
|
||||
handleWhileLikeComments,
|
||||
handleForXComments,
|
||||
handleForXStatementComments,
|
||||
handleMethodNameComments,
|
||||
handleOnlyComments,
|
||||
handleTSMappedTypeComments,
|
||||
|
||||
@@ -281,12 +281,10 @@ function printEstree(path, options, print, args) {
|
||||
return printTryStatement(path, options, print);
|
||||
case "CatchClause":
|
||||
return printCatchClause(path, options, print);
|
||||
// Note: ignoring n.lexical because it has no printing consequences.
|
||||
case "SwitchStatement":
|
||||
return printSwitchStatement(path, options, print);
|
||||
case "SwitchCase":
|
||||
return printSwitchCase(path, options, print);
|
||||
// JSX extensions below.
|
||||
case "DebuggerStatement":
|
||||
return ["debugger", options.semi ? ";" : ""];
|
||||
|
||||
|
||||
Reference in new issue
Block a user