0.1.21 • Published 8 years ago

ts-webapi-ref v0.1.21

Weekly downloads
3
License
ISC
Repository
github
Last release
8 years ago

ts-webapi-ref

A npm module for generating typescript code from Web Api Descriptions

This npm module allows to generate typescript code using the Api Descriptions provided by Web Api. It also generates Services call providing interfaces for each Web Api controller and implements the service call using angular.IHttpService. This module can be included as a gulp task in the build.

Installation:

$ npm install ts-webapi-ref

Usage:

This module has only one api "generateApi"

var tsWebApiRef = require("ts-webapi-ref");

tsWebApiRef.generateApi(url [, options]);
url: <web api endpoint exposing all the Api descriptions (see below for more details)>
options: {    
     filename: (Reference.ts) "name of the file that should contain the generated types and web api service"
     module: (Service.Reference) "name of the module for the service call interface"
     apiSuffix: (Service) "suffix name of the service interface generated."
     generateOnlyTypes: (false) "if enabled, generator will not generate service api calls"
     generateTypesAsInterface: (false) "if enabled, generator will generate the types as interfaces"
     generateTypesInSameModule: (false) "if enabled, the types are generated under provided module"
}

This is used in conjunction with WebApiExplorerExtensions nuget package in Web Api code. Please see here for more details: https://github.com/Azhaguthasan/WebApiExtensions

0.1.21

8 years ago

0.1.20

8 years ago

0.1.19

8 years ago

0.1.18

8 years ago

0.1.17

8 years ago

0.1.16

8 years ago

0.1.15

8 years ago

0.1.14

8 years ago

0.1.13

9 years ago

0.1.12

9 years ago

0.1.11

9 years ago

0.1.10

9 years ago

0.1.9

9 years ago

0.1.8

9 years ago

0.1.7

9 years ago

0.1.6

9 years ago

0.1.5

9 years ago

0.1.4

9 years ago

0.1.3

9 years ago

0.1.2

9 years ago

0.1.1

9 years ago

0.1.0

9 years ago