Ecosyste.ms: Awesome

An open API service indexing awesome lists of open source software.

Awesome Lists | Featured Topics | Projects

https://github.com/Narazaka/shiori_converter.js

SHIORI Protocol version converter
https://github.com/Narazaka/shiori_converter.js

shiori ukagaka

Last synced: 28 days ago
JSON representation

SHIORI Protocol version converter

Awesome Lists containing this project

README

        

# [shiori_converter.js](https://github.com/Narazaka/shiori_converter.js)

[![npm](https://img.shields.io/npm/v/shiori_converter.svg)](https://www.npmjs.com/package/shiori_converter)
[![npm license](https://img.shields.io/npm/l/shiori_converter.svg)](https://www.npmjs.com/package/shiori_converter)
[![npm download total](https://img.shields.io/npm/dt/shiori_converter.svg)](https://www.npmjs.com/package/shiori_converter)
[![npm download by month](https://img.shields.io/npm/dm/shiori_converter.svg)](https://www.npmjs.com/package/shiori_converter)

[![Dependency Status](https://david-dm.org/Narazaka/shiori_converter.js/status.svg)](https://david-dm.org/Narazaka/shiori_converter.js)
[![devDependency Status](https://david-dm.org/Narazaka/shiori_converter.js/dev-status.svg)](https://david-dm.org/Narazaka/shiori_converter.js?type=dev)
[![Travis Build Status](https://travis-ci.org/Narazaka/shiori_converter.js.svg?branch=master)](https://travis-ci.org/Narazaka/shiori_converter.js)
[![AppVeyor Build Status](https://ci.appveyor.com/api/projects/status/github/Narazaka/shiori_converter.js?svg=true&branch=master)](https://ci.appveyor.com/project/Narazaka/shiori-converter-js)
[![codecov.io](https://codecov.io/github/Narazaka/shiori_converter.js/coverage.svg?branch=master)](https://codecov.io/github/Narazaka/shiori_converter.js?branch=master)
[![Codacy Badge](https://api.codacy.com/project/badge/Grade/3c3903c95a37410cbe9f84f3f482f764)](https://www.codacy.com/app/narazaka/shiori_converter-js?utm_source=github.com&utm_medium=referral&utm_content=Narazaka/shiori_converter.js&utm_campaign=Badge_Grade)

SHIORI Protocol version converter

## Install

npm:
```
npm install shiorijk shiori_converter
```

This module depends on [ShioriJK](https://github.com/Narazaka/shiorijk)

## Usage

node.js:
```javascript
var shiori_converter = require('shiori_converter');
var ShioriConverter = shiori_converter.ShioriConverter;
```

browser:
```html

```

```javascript
var request3 = new ShioriJK.Message.Request({
request_line: {
method: 'GET',
version: '3.0',
},
headers: {
ID: 'OnBoot',
Charset: 'UTF-8',
Sender: 'Ikagaka',
},
});
var request2 = ShioriConverter.request_to(request3, '2.6');
console.log(request2.toString());

var response2 = new ShioriJK.Message.Response({
status_line: {
code: 200,
version: '2.6',
},
headers: {
Sentence: '\\h\\s[0]\\e',
Charset: 'UTF-8',
Sender: 'ikaga',
},
});
var response3 = ShioriConverter.response_to(request3, response2, '3.0');
console.log(response3.toString());
```

## API

[API Document](https://narazaka.github.io/shiori_converter.js/index.html)

## License

This is released under [MIT License](http://narazaka.net/license/MIT?2015).