1.2.2 • Published 4 years ago

@wearelucid/vue-bows v1.2.2

Weekly downloads
20
License
MIT
Repository
github
Last release
4 years ago

vue-bows

npm version

Vue.js plugin for clear and understandable console logs. It displays nice logs based on the component written. It makes your logs clear and organized.

Installation

yarn add @wearelucid/vue-bows

Integration & Usage

// import
import Vue from 'vue'
import Log from 'vue-bows'

Vue.use(Log)
// You are now able to use it in your components in your Project. Like this:

export default {
  name: 'MyComponent',
  data: () => ({
    variable: 'foo'
  }),
  mounted () {
    this.log('string') // logs "MyComponent // string"
    this.log(this.variable) // logs "MyComponent // foo"
    this.log('string', this.variable) // logs "MyComponent // string, foo"
  }
}

Usage outside of components

import { createLogger } from 'vue-bows'

const log = createLogger('nameOfTheLogger') // replace name with something meaningful

log('Log this')

Integration with Nuxt.js

// Create following file in your plugins folder. and Add
'plugins/vue-bows.js'

// Then add the plugin to your 'nuxt.config.js'
plugins: [
  '~/plugins/vue-bows'
]

Enable your browser

First you must enable it in your browsers console: Type localStorage.debug = true in your browser's console to activate it.

1.2.2

4 years ago

1.2.1

4 years ago

1.2.0

5 years ago

1.1.0

6 years ago