Skip to content
This repository has been archived by the owner on Dec 6, 2021. It is now read-only.

AtCurtain 报 Invalid VNode type: undefined (undefined) #53

Closed
b2nil opened this issue Oct 26, 2020 · 0 comments
Closed

AtCurtain 报 Invalid VNode type: undefined (undefined) #53

b2nil opened this issue Oct 26, 2020 · 0 comments

Comments

@b2nil
Copy link
Owner

b2nil commented Oct 26, 2020

问题描述

default slot 语法问题导致以上错误。

版本信息

v1.0.0-alpha.12

涉及的平台

h5, 小程序

错误信息

// h5
runtime-core.esm-bundler.js?5c40:38 [Vue warn]: Invalid VNode type: undefined (undefined) 
  at <TaroView class="at-curtain__body" > 
  at <TaroView class="at-curtain__container" > 
  at <TaroView class="at-curtain at-curtain--closed" onTap=fn<onTap> > 
  at <AtCurtain isOpened=false closeBtnPosition="bottom" onClose=fn<bound onClose> > 
  at <TaroView class="page" style= {width: "100%", margin: "auto"}margin: "auto"width: "100%"__proto__: Object > 
  at <Page headerTitle="Curtain 幕帘" > 
  at <CurtainDemo tid="/pages/view/curtain/index" > 
  at <App>

// weapp
VM32:1 [Vue warn]: Invalid VNode type:  (undefined) 
  at <AtCurtain isOpened=true closeBtnPosition="top" onClose=fn<bound onClose> > 
  at <Page headerTitle="Curtain 幕帘" > 
  at <CurtainDemo tid="pages/view/curtain/index?__key_=16037124863712" > 
  at <App>

代码

{ default: () => [
  { default: () => slots.default && slots.default() }, // <- 问题写法

  h(View, {...})
]}
@b2nil b2nil changed the title [h5] AtCurtain 报 Invalid VNode type: undefined (undefined) AtCurtain 报 Invalid VNode type: undefined (undefined) Oct 26, 2020
@b2nil b2nil closed this as completed in 1510079 Oct 26, 2020
@b2nil b2nil added this to the v1.0.0-alpha.13 milestone Oct 29, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant