New Research: Supply Chain Attack on Axios Pulls Malicious Dependency from npm.Details
Socket
Book a DemoSign in
Socket

veil-notification

Package Overview
Dependencies
Maintainers
1
Versions
1
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

veil-notification

Vue3 通知组件

latest
npmnpm
Version
0.0.11
Version published
Maintainers
1
Created
Source

INSTALL

yarn add veil-notifications
npm install veil-notification --save

USAGE

1.首先在全局组件中放置Notification组件,一般就放置在App.vue

<template>
  <router-view></router-view>
  <Notification/>
</template>

<script>
import Notification from 'veil-notification'
export default {
  
}
</script>

2.在代码中发送通知

import { notification } from "./components/notify"

notification.success("I'm message content")

API

notification 挂载了四个函数,分别是success/warning/info/error,参数都是一样的

  • message, //消息内容
  • duration = 2500, //持续时间
  • group = "tr", //位置: tl tr tc 左上 右上 顶部居中 bl br bc 左下 右下 底部居中
  • data, //data参数,会在点击时传递给onNotificationClick
  • onNotificationClick //点击事件

Keywords

notification

FAQs

Package last updated on 05 Jul 2021

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts