0.0.2 • Published 8 years ago

repl-kit v0.0.2

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

use Scene to sse the repl envirement

export type IEvalCallback = (err?: Error | null, ret?: any) => void

export type IMethod = (this: repl.REPLServer, args: string[], cb: IEvalCallback) => void

export interface ICommand {
  help: string,
  action: (this: repl.REPLServer) => void
}

export interface IScene {
  prompt?: string
  context?: any
  methods?: {[index: string]: IMethod}
  commands?: {[index: string]: ICommand}
}