Skip to content

Commit

Permalink
fix: 增加单文件组件value 支持
Browse files Browse the repository at this point in the history
  • Loading branch information
maxiaobo01 committed Jul 11, 2022
1 parent 3e0a3e8 commit a090aeb
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 3 deletions.
4 changes: 2 additions & 2 deletions demo/index.ts
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import './app';
// import './single';
// import './app';
import './single';
import { startUp } from '../src/utils/initEditor';

startUp();
3 changes: 2 additions & 1 deletion src/single/Editor.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,7 @@ function getStringValue(value: any) {
if (typeof value === 'number') {
return String(value);
}
return value;
return String(value);
}

export const SingleEditor = React.forwardRef<SingleEditorRefType, SingleEditorIProps>(({
Expand Down Expand Up @@ -122,6 +122,7 @@ export const SingleEditor = React.forwardRef<SingleEditorRefType, SingleEditorIP
}
sub.dispose();
blurSub.dispose();
model.dispose();
}
// eslint-disable-next-line react-hooks/exhaustive-deps
}, []);
Expand Down

0 comments on commit a090aeb

Please sign in to comment.