-
Notifications
You must be signed in to change notification settings - Fork 481
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
mp-html 渲染异常 #414
Comments
#412 是一开始能显示,多级页面返回的时候变成空白了,跟你描述的不是一个问题吧 |
2022-03-23.9.33.00.mov视频里可以看到第一次的时候文章加载是有文字并且正常显示无报错的,但是当我退出页面再重新打开这篇文章,就会出现这样异常,并且文字消失,当然我不排除可能是uni-app这边的问题 #415 将这个判断条件改回去就是没问题的,也可能是uni-app的问题? |
还有一个猜想,我尝试了一下,好像确实存在这个问题,在编译成wxml后,当我将 <wxs module="handler">
// 行内标签列表
var inlineTags = {
abbr: true,
b: true,
big: true,
code: true,
del: true,
em: true,
i: true,
ins: true,
label: true,
q: true,
small: true,
span: true,
strong: true,
sub: true,
sup: true
}
/**
* @description 是否使用 rich-text 显示剩余内容
*/
module.exports = {
use: function (item) {
if (item.c) return false
// 微信和 QQ 的 rich-text inline 布局无效
return !inlineTags[item.name] && (item.attrs.style || '').indexOf('display:inline') == -1
},
copy: function (o){
console.log(JSON.stringify(o))
return JSON.parse(JSON.stringify(o))
}
}
</wxs>
<rich-text wx:elif="{{n.an}}" id="{{n.ao}}" style="{{n.ap}}" preview="{{false}}" nodes="{{handler.copy(n.aq)}}" /> |
在
|
给我个可复现的 |
问一下,这个bug修复了吗,我项目打算用这个 |
@jieke17weiju 我没有复现出这个问题,如果你也遇到的话可以给我一个可复现的 |
好的,我先用着,复现了再提下 |
uniapp 支付宝小程序那边也有点问题,我看看能不能提供个最小复现demo |
@okxiaoliang4 有空试一下这样还会不会报错 |
好的 |
在微信小程序也遇到这个问题 vue3 |
@scholar-ink 用上面这个 |
这个问题现在还在 |
使用环境
uniapp vue3 微信小程序
问题描述
uni-app vue3 微信小程序渲染异常,在mp-html未适配vue3时我patch一个版本遇到了这个问题,现在看到mp-html更新适配vue3之后替换成官方源,逐行定位问题,发现是这行代码导致的异常
mp-html/dist/uni-app/components/mp-html/node/node.vue
Lines 62 to 63 in c6032b1
跟 #412 的表现方式应该差不多
复现方式
The text was updated successfully, but these errors were encountered: