Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/develephant/jsonp
A promise based JSON wrapper.
https://github.com/develephant/jsonp
async es2017 json promise
Last synced: 11 days ago
JSON representation
A promise based JSON wrapper.
- Host: GitHub
- URL: https://github.com/develephant/jsonp
- Owner: develephant
- License: other
- Created: 2017-03-23T00:49:23.000Z (over 7 years ago)
- Default Branch: master
- Last Pushed: 2017-03-23T00:49:31.000Z (over 7 years ago)
- Last Synced: 2024-10-11T15:17:52.828Z (about 1 month ago)
- Topics: async, es2017, json, promise
- Language: JavaScript
- Size: 1000 Bytes
- Stars: 0
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE.md
Awesome Lists containing this project
README
# `jsonp`
### A promise based JSON wrapper.
## Install
```
npm i @develephant/jsonp --save
```## Usage
```js
const jsonp = require('@develephant/jsonp')
```## Example
_async_
```js
async function doJSONStuff() {
let json_str = await jsonp.stringify(js_obj)
}
```_promise_
```js
jsonp.parse(json_str)
.then(res => console.log(res))
.catch(err => console.error(err))
```## Methods
- `stringify`
- `pretty` (formatted stringify)
- `parse`
---
#### `jsonp` ⋆ © 2017 develephant ⋆ MIT license