@lx-frontend/wx-real-time-logger
TypeScript icon, indicating that this package has built-in type declarations

0.1.1 • Public • Published

@lx-frontend/real-time-logger

小程序实时上报日志工具包 🔧

Usage

import { InitLogger } from "@lx-frontend/real-time-logger";

const { log, warn, error } = InitLogger({ enabled: true })

log(
  {hey: 'man', hello: 'world'},
  [{a: 1}, {b: 2}],
  [4, 5, 6],
  'test123567',
)

warn(
  {hey: 'man', hello: 'world'},
  [{a: 1}, {b: 2}],
  [4, 5, 6],
  'test123567',
)

error(
  {hey: 'man', hello: 'world'},
  [{a: 1}, {b: 2}],
  [4, 5, 6],
  'test123567',
)

Problem

‼️目前已知的一些微信后台过滤上报filterMsg信息 过滤不了的问题

  1. 带有特殊字符 (e.g. http://img4.bitautoimg.com/bt/car/default/images/logo/masterbrand/png/100/m_57_100.png)

  2. 中文字符 (e.g. 仁孚香港专场/2021年08月16号)

  3. 时间格式 (e.g. 2021-08-16 00:00:00 可与问题1归为一类 但考虑到这类可以单独进行兼容 所以独立出来了)

  4. 带空格的信息 (e.g. Zung Fu Outlet/金龙 金龙9米公路客车 211马力 目前通过去除空格兼容了这种情况)

Package Sidebar

Install

npm i @lx-frontend/wx-real-time-logger

Weekly Downloads

1

Version

0.1.1

License

ISC

Unpacked Size

10.3 kB

Total Files

5

Last publish

Collaborators

  • ruqimobile
  • haiyulu
  • erica.liuyj
  • pok.h
  • chenzian
  • azumia
  • jeely
  • lichao.franklee
  • mind29
  • yuki.liu
  • lixinleon
  • frontbot
  • owen.huang
  • tiny.tu
  • simba.wang