0.0.25 • Published 3 years ago
@oats-ts/generator v0.0.25
@oats-ts/generator
This package contains the generator harness for anything you might want to generate with oats. The generator expects the following configuration:
import { generate, ContentReader, ContentValidator, CodeGenerator, ContentWriter } from '@oats-ts/generator'
// Responsible for reading the your content and ensuring it's structurally correct.
const reader: ContentReader<R> = null
// Responsible for determining if your content is semantically valid. Runs after reader.
const validator: ContentValidator<R> = null
// Responsible for generating your modules. Uses the validated content.
const generator1: CodeGenerator<R, G> = null
const generator2: CodeGenerator<R, G> = null
// Responsible for writing the generated modules to disk.
const writer: ContentWriter<G> = null
// In an async context.
await generate({
// Set to false if you don't want logging.
log: true,
reader: reader,
validator: validator,
generators: [
generator1,
generator2
],
writer: writer
}
0.0.25
3 years ago
0.0.20
3 years ago
0.0.21
3 years ago
0.0.22
3 years ago
0.0.23
3 years ago
0.0.24
3 years ago
0.0.18
3 years ago
0.0.19
3 years ago
0.0.15
3 years ago
0.0.16
3 years ago
0.0.17
3 years ago
0.0.10
3 years ago
0.0.11
3 years ago
0.0.12
3 years ago
0.0.13
3 years ago
0.0.14
3 years ago
0.0.9
3 years ago
0.0.8
3 years ago
0.0.7
4 years ago
0.0.6
4 years ago
0.0.5
4 years ago
0.0.3
4 years ago
0.0.4
4 years ago
0.0.2
4 years ago
0.0.0
4 years ago