Skip to content

CodeInKit/cli

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

88 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

@codeinkit/cli

Usage

npx @codeinkit/cli init flows-server
npx @codeinkit/cli init flows-ws-server
npx @codeinkit/cli init flows-rest-server
npx @codeinkit/cli action <flow name> <action number> <data path>
npx @codeinkit/cli flow <flowName> <dataPath>

generate flows-server

A server based only structure that works with flows. With this template you can write http server, websocket, tcp socket, bot etc.

file structure

  • flows - a folder that hold the flows you have, the index will run through this folder and register the flows by the name of the file / folder. if a folder is present there has to be index.js file that the main file (same as require a folder in nodejs).
  • setup - this folder run the initial setup, for example express configuration should be put here.
  • index.js - this file run through the flows and register them after that it activate the routes.
  • routes.js - here you can write the routes related to the project, http routes, websocket etc.

@codeinkit/cli generate ws-flows-server

create a websocket server that work out of the box with client flows (ex: react-flows-client, angular-flows-client)

the file structure is the same as the flow-server but unlike the flow-server routes already written to support websocket and there is existing flow of allow_origin which allow all origins but can be change to support specific origins.

@codeinkit/cli

execute single action according to data in path

@codeinkit/cli flow

execute single flow

Contributing

Pull requests are welcome. For major changes, please open an issue first to discuss what you would like to change.

Please make sure to update tests as appropriate.

License

MIT

About

code in kit cli tool

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published