npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2024 – Pkg Stats / Ryan Hefner

x5-notify

v0.3.13

Published

A lightweight notice plugin for Vue

Downloads

9

Readme

x5 Notify (Live Demo)

npm bundle size

This is a lightweight notice plugin.

:warning: This plugin is in development, so please let me know if you find any errors.

Notices

Installation

# npm
npm install x5-notify

Deployment

This plugin does require a Vuex store and can be installed like any Vue plugin in your entry point:

Vue.use(Vuex)
const store = new Vuex.Store()

import x5Notify from 'x5-notify'
Vue.use(x5Notify, store)

new Vue({
  el: '#app',
  store: store,
  render: (h) => h(App),
})

This plugin uses a component to house all the magic, so it's recommended to put this near the end of your Vue app (e.g. bottom of your App.vue template)

<div id="app">
  ...
  <x5-notify></x5-notify>
</div>

| Attribute | Type | Default | Description | | :-------- | :----: | :----------: | :--------------------------------------------------------- | | position | String | bottom-right | Origin of notices - see options below* | | zIndex | Number | 200 | z-index style for plugin | | max | Number | 5 | Limit number of open notices (use 0 to remove limit)** |

:info: * Positions options: top-left, top-center, top-right, center-left, center-center, center-right, bottom-left, bottom-center, bottom-right

:warning: ** onClose() callbacks disabled for notices exceeding notice limit.

:warning: This plugin is not transpiled! If you want to include it for use on IE or Edge, you need to add this to your vue.config.js file:

module.exports = {
  transpileDependencies: ['x5-notify']
}

Usage

Quick Method - this.$notify(type, text)

this.$notify('success', 'This is a success notice')

Full Method: this.$notify(options)

this.$notify({ type: 'success', text: 'This is a success notice', wait: 5 })

| Options | Type | Default | Description | | :----------- | :------: | :------------------: | :----------------------------------------------------------------- | | type | String | default | One of success, warning, error, info, special, default | | text | String | -- | Notice text (required) - can be HTML | | onClose | Function | -- | Callback for when the notice is closed | | onClick | Function | -- | Callback for clicking on the notice | | onClickText | String | "(click to dismiss)" | Description of click action (bottom right hand corner) | | wait | Number | 5 | Time in seconds before notice is destroyed | | closeOnClick | Boolean | true | Closes the notice early if clicked |


Contributing

Please read CONTRIBUTING.md for the process for submitting pull requests.

Authors

License

This project is licensed under the MIT License - see the LICENSE.md file for details

Acknowledgements

Inspired by: