1.0.1 • Published 7 months ago

@rodrive/console-vlog v1.0.1

Weekly downloads
-
License
MIT
Repository
-
Last release
7 months ago

Console Vue Log

A console.log for vue

Install

npm install @rodrive/console-vlog

Usage

file: src/main.js

import { createApp } from 'vue';
import App from './App.vue';
import consoleVlog from '@rodrive/console-vlog';

createApp(App).use(consoleVlog, {
  override: false,  // override console.log() [default: false]
}).mount('#app');

file: components/foobar.vue

const foobar = ref('foo');
const reactiveObj = reactive({ bool: false });

console.vlog(foobar);
console.vlog(reactiveObj);

foobar.value = 'bar';
reactiveObj.bool = true;

Console

Ref(0): http://localhost:5173/src/App.vue:13:9
   foo
Proxy(0): http://localhost:5173/src/App.vue:14:9
   {bool: false}
Ref(1): http://localhost:5173/src/App.vue:13:9
   bar
Proxy(1): http://localhost:5173/src/App.vue:14:9
   {bool: true}
1.0.1

7 months ago

1.0.0

7 months ago