From c2e60a4aa8af9354bc986086f4793411fba621bd Mon Sep 17 00:00:00 2001 From: Matt Sherman Date: Tue, 26 Sep 2023 21:16:52 -0400 Subject: [PATCH] Fix typing for initBlock call in summary --- packages/js/product-editor/src/blocks/summary/index.ts | 9 +++------ 1 file changed, 3 insertions(+), 6 deletions(-) diff --git a/packages/js/product-editor/src/blocks/summary/index.ts b/packages/js/product-editor/src/blocks/summary/index.ts index 634fcfa6837..7801d49c280 100644 --- a/packages/js/product-editor/src/blocks/summary/index.ts +++ b/packages/js/product-editor/src/blocks/summary/index.ts @@ -1,7 +1,6 @@ /** * External dependencies */ -import { BlockConfiguration } from '@wordpress/blocks'; import { registerWooBlockType } from '@woocommerce/block-templates'; /** @@ -9,10 +8,8 @@ import { registerWooBlockType } from '@woocommerce/block-templates'; */ import blockConfiguration from './block.json'; import { Edit } from './edit'; -import { SummaryAttributes } from './types'; -const { name, ...metadata } = - blockConfiguration as BlockConfiguration< SummaryAttributes >; +const { name, ...metadata } = blockConfiguration; export { name, metadata }; @@ -22,9 +19,9 @@ export const settings = { }; export function init() { - return registerWooBlockType< SummaryAttributes >( { + return registerWooBlockType( { name, - metadata, + metadata: metadata as never, settings, } ); }