Socket
Socket
Sign inDemoInstall

@headbright/hb-universal-storage

Package Overview
Dependencies
12
Maintainers
1
Versions
1
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

    @headbright/hb-universal-storage

A universal storage library for Nuxt projects with IE and Safari 10 support.


Version published
Maintainers
1
Install size
19.8 MB
Created

Readme

Source

Universal Storage Helper

Universal storage helper for Nuxt projects with tweaks to facilitate use with older browsers.

The project is based on the equivalent nuxt community module.

Installation

  1. npm i --save @headbright/hb-universal-storage

  2. Create a nuxt plugin:

import Storage from 'hb-universal-storage'

export default function(ctx, inject) {
  const options = {
    vuex: {
      namespace: 'storage'
    },
    cookie: {
      prefix: '',
      options: {
        path: '/'
      }
    },
    localStorage: {
      prefix: ''
    },
    ignoreExceptions: false
  }
  const storage = new Storage(ctx, options)
  ctx.$storage = storage
  inject('storage', storage)
}

FAQs

Last updated on 03 Jan 2020

Did you know?

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

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc