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 🙏

© 2026 – Pkg Stats / Ryan Hefner

@vue-accounts/bare-components

v0.0.18-alpha.0

Published

Minimal Vue Account components without any styling applied

Readme

Very early WIP. Use at own risk!

A collection of prefabricated Vue plugins and mixins that simplify setting up things related to user accounts and authentication.

Demo

Coming soon..

Getting started

Install the dependencies:

npm install @vue-accounts/core

Add the store plugin to use the components with your Vuex account store

import Vuex from 'vuex';
import { AccountStorePlugin } from '@vue-accounts/core';

Vue.use(Vuex);

const store = new Vue.Store({});

Vue.use(AccountStorePlugin, { store }); // Init the plugin with the Vuex store

Add one of the example forms to your app like below

<template>
  <login-form />
</template>

<script>
  import { LoginForm } from '@vue-accounts/core';

  export default {
    components: {
      LoginForm,
    },
  };
</script>

You now have a working login form, but... It does not actually log someone in. Pressing submit will end up in an error stating that there was no store action named login. This is the nice part. You either use one of the existing plugins, or you build your own!

Account Stores

Account stores connect the AccountStorePlugin to an actual store that is tailored for a specific auth backend.

Dop-in Account Stores:

Creating a custom Account Store

You can add your own account store just like any other store:

./store.js

import account from './stores/account';

export default new Vuex.Store({
  modules: {
    account,
  }
});

./stores/account.js

export default {
  actions: {
    async login(context, { email, password }) {},
    async logout(context) {},
    async register(context, { displayName, email, password, repeatPassword }) {},
    async forgotPassword(context, { email }) {},
    async resetPassword(context, { token, password, repeatPassword }) {},
    async verifyEmail(context, { token }) {},
  },
},

Simply implement the backend methods in your store, but be sure to return a promise. This makes the component mixins able to provide a loading state to each auth component when needed.

Namespacing the Account Store module

You can have a namespaced store module. In that case set the namespace option on the AuthStorePlugin to make it aware:

Vue.use(AccountStorePlugin, { namespace: 'account' });

Components

This package comes with example components to get you set-up quickly. These components are just meant for prototyping. Its recommended to either build your own or to use a vue-accounts component package.

Drop-in component packages:

Creating custom components

Creating your own form is very easy. Simply add the right mixin and build the template like the below example:

<template>
  <form @submit.prevent="submit">
    <p><strong>Status:</strong> {{status}}</p>

    <input type="text" name="email" v-model="email" placeholder="Email" />
    <input type="password" name="password" v-model="password" placeholder="Password" />

    <p v-if="error"><strong>Error:</strong> {{error}}</p>

    <input type="submit" value="Login" />
  </form>
</template>

<script>
  import { LoginFormMixin } from '@vue-accounts/core';

  export default {
    mixins: [LoginFormMixin],
  };
</script>

The @submit event will trigger the mixin to call the right method.

Mixins

BaseFormMixin

Forms the base functionality for all the accounts forms. It calls the associated methods and tracks the status of this progress (idle, submitting, success, error). It gives the following states:

| Prop | Type | Description | Possible values | Default value | |------|-------------|-----------------|---------------|------| |status| String | A string representing the submit / loading status | 'idle', 'submitting', 'success', 'error' | 'idle' | |error | String | A string containing any error given when the method call fails | | '' | |payload| Object| An object containing the payload that is going to be send or was send by the form | | {} |

TODO Finish Documentation for the FormMixins