NervJS / taro

开放式跨端跨框架解决方案,支持使用 React/Vue/Nerv 等框架来开发微信/京东/百度/支付宝/字节跳动/ QQ 小程序/H5/React Native 等应用。 https://taro.zone/
https://docs.taro.zone/
Other
35.46k stars 4.78k forks source link

Taro Next Vue 模板中引用 template 没有被编绎 #5606

Closed febobo closed 4 years ago

febobo commented 4 years ago

问题描述

Taro Next Vue 模板中引用 template 没有被编绎

复现步骤

必现代码

<template>
  <view class="detail">
    <template is='wxParse' data="test"/> 
  </view>
</template>

效果如下图 WechatIMG8873

期望行为

正常使用template

报错信息

系统信息

👽 Taro v3.0.0-alpha.5

Taro CLI 3.0.0-alpha.5 environment info: System: OS: macOS 10.14.5 Shell: 5.3 - /bin/zsh Binaries: Node: 10.16.2 - ~/.nvm/versions/node/v10.16.2/bin/node Yarn: 1.10.1 - /usr/local/bin/yarn npm: 6.9.0 - ~/.nvm/versions/node/v10.16.2/bin/npm npmPackages: @tarojs/components: 3.0.0-alpha.5 => 3.0.0-alpha.5 @tarojs/taro: 3.0.0-alpha.5 => 3.0.0-alpha.5 eslint-config-taro: 3.0.0-alpha.5 => 3.0.0-alpha.5

taro-bot[bot] commented 4 years ago

CC @Chen-jj

taro-bot[bot] commented 4 years ago

欢迎提交 Issue~

如果你提交的是 bug 报告,请务必遵循 Issue 模板的规范,尽量用简洁的语言描述你的问题,最好能提供一个稳定简单的复现。🙏🙏🙏

如果你的信息提供过于模糊或不足,或者已经其他 issue 已经存在相关内容,你的 issue 有可能会被关闭。

Good luck and happy coding~

yuche commented 4 years ago

你可以把这个 template 写成一个自定义组件然后通过 usingComponents 来使用。

使用 wxparse 有现成的代码,具体可以参考: https://github.com/NervJS/taro-sample-weapp/tree/next/src

如果是 vue 的话: https://github.com/NervJS/taro-sample-weapp/tree/vue/src

taro-bot[bot] commented 4 years ago

Hello~

您的问题楼上已经有了确切的回答,如果没有更多的问题这个 issue 将在 15 天后被自动关闭。

如果您在这 15 天中更新更多信息自动关闭的流程会自动取消,如有其他问题也可以发起新的 Issue。

Good luck and happy coding~