fix unkown type.
This commit is contained in:
parent
c964ff5cfe
commit
8b31f495ba
1 changed files with 1 additions and 1 deletions
|
|
@ -63,7 +63,7 @@ const JsonView = memo(
|
||||||
|
|
||||||
const handleCopy = useCallback(() => {
|
const handleCopy = useCallback(() => {
|
||||||
try {
|
try {
|
||||||
navigator.clipboard.writeText(JSON.stringify(normalizedData, null, 2));
|
navigator.clipboard.writeText(typeof normalizedData === "string" ? normalizedData : JSON.stringify(normalizedData, null, 2));
|
||||||
setCopied(true);
|
setCopied(true);
|
||||||
} catch (error) {
|
} catch (error) {
|
||||||
toast({
|
toast({
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue