Registry / auth-security / vue-jwt-auth

vue-jwt-auth

JSON →
library0.12.4-movedjsnpmunverified

This package is deprecated and has been moved to @websanova/vue-auth. The last version is 0.12.4-moved. It was a Vue.js JWT authentication plugin providing login, logout, token storage, and HTTP interceptors. It is replaced by the more feature-rich @websanova/vue-auth package which supports multiple authentication types (JWT, OAuth, etc.) and drivers (axios, fetch, etc.). Do not use this package; migrate to @websanova/vue-auth.

npm install vue-jwt-auth
INSTALL
IMPORT
SIG · VUE-JWT-AUTH
V
vue-jwt-auth
auth-securityjavascriptv0.12.4-moved
Install
Import
Disk
Pass rate
0/ 6
Env Coverage0 / 6
glibc
1822
musl
1822
Install & Compatibility
Where this runs
tested against v? · npm install
Install × environment matrix
Each cell = how many times install + import succeeded across repeated harness runs. Partial = flaky.
glibc = Debian/Ubuntu slim · musl = Alpine Linux
musl
node 18226 runs
build_error
glibc
node 18226 runs
build_error
Code
Verified usage

Verified import paths — ran on the pinned version, not inferred.

VueJwtAuth
import VueJwtAuth from 'vue-jwt-auth'
import { VueJwtAuth } from 'vue-jwt-auth'
Default export; named import does not work.
Vue.use(VueJwtAuth, options)
Vue.use(VueJwtAuth, options)
new VueJwtAuth(options)
Must be used as a plugin via Vue.use().
this.$auth
this.$auth.login(credentials)
this.$auth.login(credentials).catch(...)
$auth is injected globally; login returns a promise.

Sets up vue-jwt-auth with default routes and redirects. This package is deprecated; prefer @websanova/vue-auth instead.

import Vue from 'vue'; import VueJwtAuth from 'vue-jwt-auth'; Vue.use(VueJwtAuth, { register: '/api/register', login: '/api/login', logout: '/api/logout', auth: '/api/user', token: '/api/token', refresh: '/api/refresh', token_type: 'Bearer', token_name: 'access_token', refresh_token_name: 'refresh_token', auth_redirect: '/login', login_redirect: '/dashboard', register_redirect: '/dashboard', logout_redirect: '/login', forbidden_redirect: '/401', not_found_redirect: '/404', forbidden_page: '/401', not_found_page: '/404' }); new Vue({ router, store, render: h => h(App) }).$mount('#app');
Debug
Known issues
deprecatedvue-jwt-auth is deprecated and renamed to @websanova/vue-auth
fix
Migrate to @websanova/vue-auth.
affects: >=0.12.4-moved
breakingThe package has been completely rewritten. API interface is different from vue-jwt-auth.
fix
Read the documentation of @websanova/vue-auth for new API.
affects: *
Errors
Common errors & fixes
Cannot find module 'vue-jwt-auth'
Package renamed or not installed.
fix
Use npm install @websanova/vue-auth instead.
TypeError: VueJwtAuth is not a constructor
Using new VueJwtAuth() instead of Vue.use().
fix
Use Vue.use(VueJwtAuth, options).
Upgrade
Version history
0.12.4-movedlatest on npm
Audit
Dependencies

No dependency data recorded yet.

Agent activity
28 hits · last 30 days
node
22
OpenAI (training)
1
Resources
vue-jwt-auth — npm install vue-jwt-auth · libregistry