Skip to content

Commit 537427b

Browse files
nullptr-zhy
authored andcommitted
fix: 修复文档图片加载问题
1 parent 2d79cb5 commit 537427b

File tree

1 file changed

+0
-9
lines changed

1 file changed

+0
-9
lines changed

website/src/component/Preview/index.js

Lines changed: 0 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -41,15 +41,6 @@ const getBooleanValue = (param, field, defaultValue) => {
4141
const Preview = ({ path, ...mdData }) => {
4242
const $dom = useRef(null);
4343

44-
const transformImageUri = (url) => {
45-
const callback = (path) => {
46-
const reqImage = require.context(path, true, /\.(png|gif|jpg|svg)$/);
47-
const urlImage = reqImage(url);
48-
return urlImage;
49-
};
50-
return mdData.transformImageUriPath(callback);
51-
};
52-
5344
return (
5445
<Wrapper ref={$dom}>
5546
<Markdown

0 commit comments

Comments
 (0)