Skip to content

支付宝小程序支持作用域插槽 #1253

Closed
@zhuowenli

Description

新功能描述
支付宝小程序原生已实现了作用域插槽 slot-scope,但是通过 uni-app 编译后无法正常使用,希望可以支持下。

https://miniapp.open.taobao.com/doc.htm?spm=a219a.7386797.0.0.1bb8669ax91ViD&source=search&docId=117181&docType=1

现状及问题
vue:

<HlgCard title="test">
    test
    <template #footer="{title}">
        <div>{{ title }}</div>
    </template>
</HlgCard>

编译后的代码:

<hlg-card vue-id="2" title="test" class="data-v-17e670d4" onVueInit="__l">
    <view slot="footer">
        <view class="_div data-v-17e670d4">{{title}}</view></view>test</hlg-card>

期望编译代码:

<hlg-card vue-id="2" title="test" class="data-v-17e670d4" onVueInit="__l">
    <view slot="footer" slot-scope="props">
        <view class="_div data-v-17e670d4">{{props.title}}</view></view>test</hlg-card>

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions