knoc
TypeScript icon, indicating that this package has built-in type declarations

0.0.5-canary-6 • Public • Published

CAUTION: Work in progress. Not stable.

Knoc

A bell like plugin for authentication with Hapi.js, with the freedom of custom handler logic. Supports -[x] Facebook

Installation

npm install knoc --save
yarn add knoc

Usage

// facebook oauth
import {fb, FacebookConfig} from 'knoc';
import config '/path/to/my/config';

const fbHandler = async (req, h) => {
  const token = request.payload.token;
  // Pass in the config
  const fbConfig:FacebookConfig = config.facebook;
  return data = await fb.validate(token, fbConfig);
}

Readme

Keywords

none

Package Sidebar

Install

npm i knoc

Weekly Downloads

0

Version

0.0.5-canary-6

License

MIT

Unpacked Size

39.3 kB

Total Files

16

Last publish

Collaborators

  • sahalsajjad