1.1.3 • Published 2 years ago

@blackwall/api-requests-nuxt v1.1.3

Weekly downloads
1
License
MIT
Repository
gitlab
Last release
2 years ago

Nuxt module for api-requests

📖 Release Notes

Setup

  • Add api-requests-nuxt dependency to your project
  • Add api-requests-nuxt to modules section of nuxt.config.js
  • Add @nuxtjs/axios dependency to your project and to modules section of nuxt.config.js

WARNING: it's important to add @nuxtjs/axios after api-requests-nuxt!

{
  modules: [
    ['api-requests-nuxt', {
      apiDirectory: path.resolve(__dirname, 'api'),
      debug: true, // default is false
      injectKey: 'request', // default is 'api'
    }],
    '@nuxtjs/axios'
 ]
}

Usage

You can use api-requests by calling this.$api[REQUEST_NAME](REQUEST_PARAMS) in Vue object or Vuex actions.

Set debug option to false to disable logging of successful requests.

Set injectKey option to request, for example, to call api-request with this.$request instead of this.$api.

License

MIT License

Copyright (c) Bitch Intelligence we@bitch.team (https://bitch.team/)

1.1.1

2 years ago

1.1.0

2 years ago

1.0.9

2 years ago

1.0.8

2 years ago

1.0.7

2 years ago

1.1.3

2 years ago

1.1.2

2 years ago

1.0.6

2 years ago

1.0.5

4 years ago