From f695853807ae09ce2741d07c2284e568b2bd75b8 Mon Sep 17 00:00:00 2001 From: Mirone Saul Date: Mon, 12 Sep 2022 17:51:22 +0800 Subject: [PATCH] =?UTF-8?q?refactor:=20=F0=9F=92=A1=20remove=20unnessesay?= =?UTF-8?q?=20eslint=20comment?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- packages/utils/src/factory/create-mark.ts | 7 +++---- packages/utils/src/factory/create-node.ts | 7 +++---- 2 files changed, 6 insertions(+), 8 deletions(-) diff --git a/packages/utils/src/factory/create-mark.ts b/packages/utils/src/factory/create-mark.ts index 4631a0362b7..646dc8fa960 100644 --- a/packages/utils/src/factory/create-mark.ts +++ b/packages/utils/src/factory/create-mark.ts @@ -67,12 +67,11 @@ export const createMark = ({ [id]: options!.view!(ctx) }) - : undefined, + view: viewOption ? (ctx: Ctx) => ({ [id]: viewOption(ctx) }) : undefined, }; pipelineCtx.set(idPipeCtx, id); diff --git a/packages/utils/src/factory/create-node.ts b/packages/utils/src/factory/create-node.ts index 1e89f590046..215af162479 100644 --- a/packages/utils/src/factory/create-node.ts +++ b/packages/utils/src/factory/create-node.ts @@ -65,12 +65,11 @@ export const createNode = ({ [id]: options!.view!(ctx) }) - : undefined, + view: viewOption ? (ctx: Ctx) => ({ [id]: viewOption(ctx) }) : undefined, }; pipelineCtx.set(idPipeCtx, id);