From b29239422e7a0f7f5e1a4a70d4c3d3f19d825bd1 Mon Sep 17 00:00:00 2001 From: mikoloism Date: Wed, 26 Apr 2023 17:11:07 +0330 Subject: [PATCH] refactor(shared): refactor to inline typos and inline reducer for `genStaticKeys` --- src/shared/util.ts | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/src/shared/util.ts b/src/shared/util.ts index 6eb54fdb4ef..e6f2af10697 100644 --- a/src/shared/util.ts +++ b/src/shared/util.ts @@ -286,9 +286,7 @@ export function genStaticKeys( modules: Array<{ staticKeys?: string[] } /* ModuleOptions */> ): string { return modules - .reduce((keys, m) => { - return keys.concat(m.staticKeys || []) - }, [] as string[]) + .reduce((keys, m) => keys.concat(m.staticKeys || []), []) .join(',') }