Comparing version 0.1.5 to 1.0.0
@@ -10,3 +10,3 @@ 'use strict'; | ||
const json = (type, msg, obj) => { | ||
var json = { | ||
const json = { | ||
success: true, | ||
@@ -13,0 +13,0 @@ msg: '', |
{ | ||
"name": "qiao-json", | ||
"version": "0.1.5", | ||
"version": "1.0.0", | ||
"description": "nodejs json data", | ||
@@ -21,3 +21,3 @@ "author": "uikoo9 <uikoo9@qq.com>", | ||
}, | ||
"gitHead": "4662db4eb48670f7fbc6ecb588bc1a3466183b6b" | ||
"gitHead": "a39056031125576209cebe5570ba76bf1a3ec3df" | ||
} |
@@ -1,62 +0,33 @@ | ||
# qiao-json | ||
## qiao-json | ||
## api | ||
[![npm version](https://img.shields.io/npm/v/qiao-json.svg?style=flat-square)](https://www.npmjs.org/package/qiao-json) | ||
[![npm downloads](https://img.shields.io/npm/dm/qiao-json.svg?style=flat-square)](https://npm-stat.com/charts.html?package=qiao-json) | ||
### json | ||
nodejs 下 qiao-z 中的 json 数据结构 | ||
```javascript | ||
'use strict'; | ||
## usage | ||
var q = require('qiao-json'); | ||
var json = q.json('success', 'test', {}); | ||
console.log(json); | ||
``` | ||
### success | ||
```javascript | ||
'use strict'; | ||
// commonjs | ||
const { success, info, warning, danger } = require('qiao-json'); | ||
var q = require('qiao-json'); | ||
var success = q.success('test', {}); | ||
console.log(success); | ||
// es6 | ||
import { success, info, warning, danger } from 'qiao-json'; | ||
``` | ||
### info | ||
## api | ||
```javascript | ||
'use strict'; | ||
const { success, info, warning, danger } = require('qiao-json'); | ||
var q = require('qiao-json'); | ||
var info = q.info('test', {}); | ||
console.log(info); | ||
const json = success('test', {}); | ||
console.log(json); | ||
``` | ||
### warning | ||
## version | ||
```javascript | ||
'use strict'; | ||
### 0.0.7.202030207 | ||
var q = require('qiao-json'); | ||
1. 1.0.0 | ||
var warning = q.warning('test', {}); | ||
console.log(warning); | ||
``` | ||
### danger | ||
```javascript | ||
'use strict'; | ||
var q = require('qiao-json'); | ||
var danger = q.danger('test', {}); | ||
console.log(danger); | ||
``` | ||
## version | ||
### 0.0.6.20220417 | ||
@@ -63,0 +34,0 @@ |
@@ -8,3 +8,3 @@ /** | ||
export const json = (type, msg, obj) => { | ||
var json = { | ||
const json = { | ||
success: true, | ||
@@ -11,0 +11,0 @@ msg: '', |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
No v1
QualityPackage is not semver >=1. This means it is not stable and does not support ^ ranges.
Found 1 instance in 1 package
1
3950
56