From 431629736bc2a99eaadc9493daa10fdf691dfa3f Mon Sep 17 00:00:00 2001 From: liangping <18786721@qq.com> Date: Sat, 11 Sep 2021 10:33:21 +0800 Subject: [PATCH] Fix issue --- src/views/ObjectFieldComponent.vue | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/src/views/ObjectFieldComponent.vue b/src/views/ObjectFieldComponent.vue index 15847c5c..ff6d3967 100644 --- a/src/views/ObjectFieldComponent.vue +++ b/src/views/ObjectFieldComponent.vue @@ -122,7 +122,10 @@ export default { return tokenFormatter(value) }, addNewLine(value) { - return value.replaceAll('\\n', '\n') + if (typeof value === 'string') { + return value.replaceAll('\\n', '\n') + } + return value }, }, }