Skip to content
On this page

Empty 空状态

空状态时的展示占位图。

何时使用

  • 当目前没有数据时,用于显式的用户提示。
  • 初始化场景时的引导创建流程。

基础用法

empty

暂无数据

<template>
    <n-empty />
</template>

自定义图片

empty

暂无数据

通过设置 image 属性传入图片 URL。
<template>
    <n-empty
        image="https://shadow.elemecdn.com/app/element/hamburger.9cf7b091-55e9-11e9-a976-7f4d0b07eef6.png"
    />
</template>

自定义 description

empty

自定义description

<template>
    <n-empty description="自定义description" />
</template>

Empty 属性

属性名说明类型可选值默认值
image图片地址string
description描述string

Released under the MIT License.