@dokoo/vue
TypeScript icon, indicating that this package has built-in type declarations

0.0.5 • Public • Published

Dokoo Vue Plugin

Installation

yarn add @dokoo/vue

Configure the plugin in your main.js:

import Vue from 'vue'
import Dokoo from '@dokoo/vue'

Vue.use(Dokoo({
  clients: {
    default: {
      token: '<your-auth-token>'
    }
  }
}))

Usage

You are ready to go! Use it in any of your component:

export default {
  data () {
    return {
      hits: []
    }
  },
  async fetch () {
    const feed = this.$dokoo.default.feeds.getFeed('<your-feed-id>')
    const { hits } = await feed.get()
    this.hits = hits
  }    
}

Read more documentation on the Javascript Dokoo Client:

Readme

Keywords

none

Package Sidebar

Install

npm i @dokoo/vue

Weekly Downloads

1

Version

0.0.5

License

MIT

Unpacked Size

4.23 kB

Total Files

7

Last publish

Collaborators

  • dokoo