Skip to content

Commit 6b062e8

Browse files
committed
fix: type error
1 parent 0c4d902 commit 6b062e8

File tree

1 file changed

+6
-2
lines changed

1 file changed

+6
-2
lines changed

Diff for: web-devtools/src/components/JSONEditor.tsx

+6-2
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,11 @@
11
import React, { useEffect, useRef } from "react";
22
import styled, { css } from "styled-components";
33

4-
import { createJSONEditor, type JSONEditorPropsOptional, JsonEditor } from "vanilla-jsoneditor";
4+
import {
5+
createJSONEditor,
6+
type JSONEditorPropsOptional,
7+
type JsonEditor as VanillaJsonEditor,
8+
} from "vanilla-jsoneditor";
59

610
import { landscapeStyle } from "styles/landscapeStyle";
711

@@ -35,7 +39,7 @@ const Container = styled.div`
3539

3640
const JSONEditor = (props: any) => {
3741
const refContainer = useRef<HTMLDivElement | null>(null);
38-
const refEditor = useRef<JsonEditor | null>(null);
42+
const refEditor = useRef<VanillaJsonEditor | null>(null);
3943
const refPrevProps = useRef<JSONEditorPropsOptional>(props);
4044

4145
useEffect(() => {

0 commit comments

Comments
 (0)