npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2024 – Pkg Stats / Ryan Hefner

mm-coa-nuxt

v0.0.1

Published

project basic faramework for nuxt

Downloads

8

Readme

mm-coa-nuxt

GitHub license npm version npm downloads PRs Welcome

一个基于 Nuxt 的前端集成框架,包含了 Nuxt 基本框架、常用方法、必要的第三方类库

使用说明

安装

yarn add mm-coa-nuxt

框架

🚧 文档建设中

组件

Gateway 接口网关

🚧 文档建设中

storage 储存

import { storage } from 'mm-coa-nuxt'

// 设置本地储存
storage.local.set('key1', { info: 'value1' }, 10 * 60 * 1000 /*10分钟有效期*/)
// 获取本地储存
storage.local.get('key1')

// 设置会话储存
storage.session.set('key2', { info: 'value2' }, 10 * 60 * 1000 /*10分钟有效期*/)
// 获取会话储存
storage.session.get('key2')

time 时间

time 包含了一些常用时间常量,单位为毫秒

import { time } from 'mm-coa-nuxt'

// 1秒钟 1000
time.oneSecond
// 1分钟 60*1000
time.oneMinute
// 1小时 60*60*1000
time.oneHour
// 1天 24*60*60*1000
time.oneDay
// 1周 7*24*60*60*1000
time.oneWeek
// 1个月 30*24*60*60*1000
time.oneMonth
// 1年 365*24*60*60*1000
time.oneYear
// 1世纪 100*365*24*60*60*1000
time.oneCentury
// 永久(100世纪) 100*100*365*24*60*60*1000
time.forever

echo 输出

import { echo } from 'mm-coa-nuxt'

// 输出一个信息
echo.log('this is message')

// 输出一个信息并报错
echo.error('this is message with error')

die 终止

import { die } from 'mm-coa-nuxt'

// 终止代码运行并给出提示信息
die.hint('error message')

第三方库

包含以下第三方库

// 获取 dayjs 对象,dayjs的使用详见 https://day.js.org/zh-CN
import { dayjs } from 'mm-coa-nuxt'

// 获取 lodash 对象,lodash的使用详见 https://lodash.com
import { lodash } from 'mm-coa-nuxt'

// lodash 存在别名 _ ,也可以直接导入
import { _ } from 'mm-coa-nuxt'