From dedcf17d533aab0c5641b842877e42440883d5d8 Mon Sep 17 00:00:00 2001 From: Jessica Chong Date: Thu, 2 Dec 2021 05:13:03 -0800 Subject: [PATCH] feat: Add `as` option and pass through to ReactRenderer (#2213) * Add `as` option and pass through to ReactRenderer * Fix type, oops * type `as` as string --- packages/react/src/ReactNodeViewRenderer.tsx | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) diff --git a/packages/react/src/ReactNodeViewRenderer.tsx b/packages/react/src/ReactNodeViewRenderer.tsx index fc12bc49..a6d9505a 100644 --- a/packages/react/src/ReactNodeViewRenderer.tsx +++ b/packages/react/src/ReactNodeViewRenderer.tsx @@ -20,6 +20,7 @@ export interface ReactNodeViewRendererOptions extends NodeViewRendererOptions { newDecorations: Decoration[], updateProps: () => void, }) => boolean) | null, + as?: string, } class ReactNodeView extends NodeView { @@ -81,12 +82,15 @@ class ReactNodeView extends NodeView