Skip to content

colmer/nuxt-client-init-module

 
 

Repository files navigation

nuxtClientInit module

code style: prettier donate: Patreon License: MIT NPM version All Contributors NPM downloads codecov

Provide client version of nuxtServerInit.

nuxt-client-init-module provides Nuxt.js with the ability to inject processing at client initialization. Just like nuxtServerInit, it is possible to implement the nuxtClientInit action, which is executed only on the client-side rendering, in the root Vuex module.

Installation

$ yarn add nuxt-client-init-module

Usage

on nuxt.config.js

{
  ...
  modules: [
   'nuxt-client-init-module'
  ]
  ...
}

on store/index.js

export const actions = {
  nuxtClientInit({ commit }, context) {
    // code
  }
}

Author

LICENSE

MIT

Contributors

Thanks goes to these wonderful people (emoji key):

HANATANI Takuma
HANATANI Takuma

💻 🐛 👀 💬
tosuke
tosuke

🐛
Masaya Kazama
Masaya Kazama

🐛
Nikita Umnov
Nikita Umnov

💻

This project follows the all-contributors specification. Contributions of any kind welcome!

Packages

No packages published

Languages

  • JavaScript 88.0%
  • Vue 12.0%