Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/cam-inc/node-vironlib
Generic library for Viron
https://github.com/cam-inc/node-vironlib
admin-library express-middleware library nodejs oas viron
Last synced: 5 days ago
JSON representation
Generic library for Viron
- Host: GitHub
- URL: https://github.com/cam-inc/node-vironlib
- Owner: cam-inc
- License: mit
- Created: 2017-07-27T02:43:08.000Z (over 7 years ago)
- Default Branch: master
- Last Pushed: 2023-10-03T01:24:38.000Z (about 1 year ago)
- Last Synced: 2024-04-18T10:15:09.015Z (7 months ago)
- Topics: admin-library, express-middleware, library, nodejs, oas, viron
- Language: JavaScript
- Homepage: https://github.com/cam-inc/viron/
- Size: 243 KB
- Stars: 20
- Watchers: 15
- Forks: 2
- Open Issues: 0
-
Metadata Files:
- Readme: README.ja.md
- License: LICENSE
- Audit: audit_log/README.md
Awesome Lists containing this project
README
# node-vironlib
Generic library for [Viron](https://github.com/cam-inc/viron/)[![npm](https://nodei.co/npm/node-vironlib.png)](https://nodei.co/npm/node-vironlib/)
[![MIT License](http://img.shields.io/badge/license-MIT-blue.svg?style=flat)](LICENSE)
[![npm](https://img.shields.io/npm/dt/node-vironlib.svg)](README.md)
[![node](https://img.shields.io/node/v/node-vironlib.svg)](README.md)## 概要
node-vironlibは、Viron API Serverで一般的に必要になるであろう機能を容易に実装出来るようにするヘルパーライブラリです。
## 機能
- [x] [認証](auth)
- [x] Google OAuth
- [x] e-mail/password
- [x] [アクセス権限(ロール)](admin_role)
- [x] [ユーザ管理](admin_user)
- [x] [監査ログ](audit_log)
- [x] [Access Control for CORS](acl)
- [x] [ページャー](pager)
- [x] [オートコンプリート](autocomplete)## クイックスタート
### インストール
```
$ npm install node-vironlib
```### 組み込み方法
```
const app = require('express')();
const VironLib = require('node-vironlib');
const vironlib = new VironLib({...}); // @see https://cam-inc.github.io/viron-doc/docs/adv_vironlib.html// middleware
app.use(vironlib.swagger.middlware());
app.use(vironlib.auditLog.middleware());
app.use(vironlib.auth.google.middleware());
app.use(vironlib.adminRole.middleware());
app.use(vironlib.bodyCompletion.middleware());// controller
app.post(vironlib.auth.controller.signIn);
app.post(vironlib.auth.controller.signOut);
app.get(vironlib.swagger.controller.show);
...
```## テスト
```
npm test
```## Migration
- [migration.ja.md](migration.ja.md)
- > 1.7.0## Copyright
CA Mobile, Inc. All rights reserved.
## LICENSE
@see : [LICENSE](LICENSE)