UNPKG

@vxe-ui/core

Version:
15 lines (14 loc) 383 B
import { getI18n } from './i18n'; function createLog(type, name) { return function (key, args) { const msg = `[vxe ${name || ''}] ${getI18n(key, args)}`; console[type](msg); return msg; }; } const version = "4.0.39"; export const log = { create: createLog, warn: createLog('warn', `v${version}`), err: createLog('error', `v${version}`) };