1.0.3 • Published 8 years ago

pancake-agent v1.0.3

Weekly downloads
-
License
MIT
Repository
-
Last release
8 years ago

pancake-agent

NPM version Build status Dependency Status Downloads

Overview

pancake-agent is an agent library to execute the PTC(Pancake Target Code), which is based on strongloop/loopback.

Pancake is a tool to generate PTC(Pancake Target Code) which can be executed by pancake-agent and exposes a loopback-compatible API.

PTC is an abbreviation of Pancake Target Code, which is the JSON files collection of an embedable DSL that expresses models what user defined in pancake documents.

Installation

$ npm install pancake-agent --save

Usage

const app = require('pancake-agent')(__dirname, () => {
  // here we can access:
  // - app.models
});

API

The pancake-agent library only exposes 1 main function as below arguments:

nametypedescription
pathnameStringthe pathname to load PTC
onbootFunctionfired when app booted

For more detail APIs, see Loopback API

License

MIT @ WeFlex, Inc