lluvio / Vue Logger
Licence: mit
log plugin for vuejs,vue 日志插件
Stars: ✭ 12
Programming Languages
javascript
184084 projects - #8 most used programming language
Projects that are alternatives of or similar to Vue Logger
Vue Music Player
🎵Vue.js写一个音乐播放器+📖One(一个).A music player + One by Vue.js
Stars: ✭ 729 (+5975%)
Mutual labels: vue2
List Pull Loading
list-pull-loading是一个基于VUE实现的下拉刷新,上拉加载的组件。主使用IScroll(iscroll-probe)来实现,提供了项目中数据列表经常会用到的下拉提示信息、上拉提示信息、图片懒加载、回到顶部,其提示信息UI、内容可灵活配置,可使用提供的默认样式也可以自定义也可以隐藏。
Stars: ✭ 17 (+41.67%)
Mutual labels: vue2
Vuejs Paginate
A Vue.js(v2.x+) component for creating pagination.
Stars: ✭ 697 (+5708.33%)
Mutual labels: vue2
Vue Koa Demo
🔰A simple full stack demo(CSR & SSR & Docker Support) written by Vue2 & Koa2(Koa1 verson also completed)
Stars: ✭ 730 (+5983.33%)
Mutual labels: vue2
Vue Music
基于vue2.0的网易云音乐播放器,api来自于NeteaseCloudMusicApi,v2.0为最新版本
Stars: ✭ 855 (+7025%)
Mutual labels: vue2
V Region
A simple region cascade selector, provide 4 levels Chinese administrative division data
Stars: ✭ 726 (+5950%)
Mutual labels: vue2
Vue2 Datatable
The best Datatable for Vue.js 2.x which never sucks. Give us a star 🌟 if you like it! (DEPRECATED. As I, @kenberkeley, the only maintainer, no longer works for OneWay. Bugs may be fixed but new features or breaking changes might not be merged. However, it's still the best in my mind because of its extremely flexible usage of dynamic components)
Stars: ✭ 867 (+7125%)
Mutual labels: vue2
Vue Qq
🎨 Vue family bucket with socket.io and express/koa2 , create a web version of mobile QQ, supporting real-time group chat, real-time private chat, special care, shielding chat, smart IP geographic location, real-time display temperature and other QQ core functions
Stars: ✭ 861 (+7075%)
Mutual labels: vue2
Vue logger
文档(Document): English
适用于 vue 1.x 和 2.x
安装
npm install vue-logger --save
使用
引入
import vueLogger from "vue-logger";
Vue.use(vueLogger, {
prefix: () => new Date(),
dev: true,
shortname: true,
levels: ["log", "warn", "debug", "error", "dir"],
forceLevels: []
});
调用
export default {
mounted() {
// 当 shortname 为 true 时, 默认为true
this.$error("hello world");
// 全局使用
Vue.console.log("hello world");
}
};
默认 levels ['log', 'warn', 'debug', 'error', 'dir']
, 你可以额外添加,
Vue.use(vueLogger, { levels: ["info"] });
// 在组件中使用
this.$info("hello world");
// log依旧可以使用
this.$log("hello world");
关于shortname
,默认是 true
,如果不想要别名,可以这么调用
this.$console.log();
Options
Name | Type | Default | Desc |
---|---|---|---|
prefix | string | None | 日志前缀,可以通过 function 动态添加 |
dev | boolean | true | 日志开关,可选择在生产环境中关闭 |
shortname | boolean | true | |
levels | array | ['log', 'warn', 'debug', 'error', 'dir'] | |
forceLevels | array | [] | 无视 dev 的配置 强制打印 |
开发
# install deps
npm install
# build dist files
npm run build
# run all tests
npm test
TODO
- [ ] sentry
Note that the project description data, including the texts, logos, images, and/or trademarks,
for each open source project belongs to its rightful owner.
If you wish to add or remove any projects, please contact us at [email protected].