1.38.0 • Published 3 years ago

@tomfrenken/generator v1.38.0

Weekly downloads
-
License
Apache-2.0
Repository
github
Last release
3 years ago

@tomfrenken/generator

Generate your own service module using a service specification (.edmx file).

Installation

$ npm install @tomfrenken/generator

Usage (CLI)

The generator is primarily meant to be used on the command line:

generate-odata-client --inputDir path/to/your/service-specification(s) --outputDir path/where/the/modules/are/stored

Run generate-odata-client --help for further options.

Usage (programatically)

You can also use the generator programmatically. You will have to provide the options anyways.

import { generateProject } from '@tomfrenken/generator';

// initialize generator options based on what you want to do
const options: GeneratorOptions = initializeOptions();

// creates a Project datastructure with all sourcefiles based on your options
const project = generateProject(options);

// here you can modify you project if you need to

// save the files at the specified location
project.save();

// alternatively you can generate and save the project in one step with: generate(options)

Documentation

Getting started guide API documentation

Helpful Links