JSPM

meeko

1.7.21
  • ESM via JSPM
  • ES Module Entrypoint
  • Export Map
  • Keywords
  • License
  • Repository URL
  • TypeScript Types
  • README
  • Created
  • Published
  • Downloads 2264
  • Score
    100M100P100Q139629F
  • License MIT

meeko自用函数

Package Exports

  • meeko

This package does not declare an exports field, so the exports above have been automatically detected and optimized by JSPM instead. If any package subpath is missing, it is recommended to post an issue to the original package (meeko) to support the "exports" field. If that is not possible, create a JSPM override to customize the exports field for this package.

Readme

meeko

Build Stat Coverage Status Codacy Badge

NPM

Standard - JavaScript Style Guide

全局函数

let $ = require('meeko') ##$.math.linearFitting(xArray,yArray) 线性拟合

json color format

  • $.dir(object)
  • 内部10行代码实现 注意字符串下标数组无法显示

JSON color format

###$.compare

let cnDictObj = {items:[{'name':'a',lev:1},{name:'b',lev:2}]}
$.log(cnDictObj.items.sort(compare('lev', 'desc'))) //默认升序

String原型扩展

  • upperFirst() 将首字母变成大写,其他小写
  • String.render(o) 字符串模板渲染

Notice

$.tools.checkParam(obj)

  • obj 如果为日期格式,日期格式为UTC日期
  • 请在前端写入mysql之前 date.date2Str()一下
  • 否则需要主动调用mysql的转换utc时间的函数