0.0.3 • Published 3 years ago

create-stack-info v0.0.3

Weekly downloads
-
License
MIT
Repository
github
Last release
3 years ago

stack-info

returns a schema for an application stack. Used by NoStack.

codecov Version Downloads/week License

Geenee Template

What

A tool for specifying a schema for the data needs of an application. Exports a schema type. Useful for templates for NoStack applications, and for some templates that provide front end code for showing or using dynamic data.

WARNING: still under construction.

Usage

First, install the package:

npm i stack-info

Here is a sample usage:

const stack-info = require('stack-info')

API

async function stackInfo: Schema (settings: NsInfo, config: Configuration)
  • The settings parameter is a NsInfo as exposed in magicalstrings. It is the settings for a given code base generated by a template.
  • The configuration is aConfiguration type from cogs-box. The template has the configuration, which specifies what is necessary for the settings.

The output is a Schema type. Following are the keys for a Schema:

  topSource: string;
  userClasses: UserClasses;
  sources: Sources;
  types: Types;
  actions: ActionsByActionType;
  backend?: BackendData;
  context?: ContextSupport;

For more details, check out the interface in the code.