From efdf1c7cf8aec1f827cfcb33266870a732a28c4a Mon Sep 17 00:00:00 2001 From: jjrv Date: Wed, 28 Feb 2018 19:44:20 +0200 Subject: [PATCH] Update readme. --- README.md | 54 ++++++++++++++++++++++++++++++++++-------------------- 1 file changed, 34 insertions(+), 20 deletions(-) diff --git a/README.md b/README.md index 401c01b..49f9ee5 100644 --- a/README.md +++ b/README.md @@ -41,7 +41,11 @@ Docs generated using [`docts`](https://github.com/charto/docts) > > ### Class [`ClassSpec`](#api-ClassSpec) > Class or interface and its members. -> Source code: [`<>`](http://github.com/charto/readts/blob/b2ca837/src/ClassSpec.ts#L11-L59) +> Source code: [`<>`](http://github.com/charto/readts/blob/ed8b215/src/ClassSpec.ts#L11-L59) +> +> Methods: +> > **new( )** [ClassSpec](#api-ClassSpec) [`<>`](http://github.com/charto/readts/blob/ed8b215/src/ClassSpec.ts#L14-L20) +> >  ▪ spec SymbolSpec > > Properties: > > **.name** string @@ -60,20 +64,24 @@ Docs generated using [`docts`](https://github.com/charto/docts) > > ### Interface [`FormatHooks`](#api-FormatHooks) > Hooks to change how parts of type definitions are converted to strings. -> Source code: [`<>`](http://github.com/charto/readts/blob/1162bd5/src/TypeSpec.ts#L11-L20) +> Source code: [`<>`](http://github.com/charto/readts/blob/ed8b215/src/TypeSpec.ts#L11-L20) > > Properties: -> > **.unknown**? (spec: TypeSpec, output?: string, hooks?: FormatHooks) => string -> > **.ref**? (spec: TypeSpec, output?: string, hooks?: FormatHooks) => string -> > **.array**? (spec: TypeSpec, output?: string, hooks?: FormatHooks) => string -> > **.union**? (spec: TypeSpec, output?: string, hooks?: FormatHooks) => string -> > **.intersection**? (spec: TypeSpec, output?: string, hooks?: FormatHooks) => string -> > **.generic**? (spec: TypeSpec, output?: string, hooks?: FormatHooks) => string +> > **.unknown**? FormatHook +> > **.ref**? FormatHook +> > **.array**? FormatHook +> > **.union**? FormatHook +> > **.intersection**? FormatHook +> > **.generic**? FormatHook > > > ### Class [`FunctionSpec`](#api-FunctionSpec) > Function or method with any number of overloaded signatures. -> Source code: [`<>`](http://github.com/charto/readts/blob/b2ca837/src/FunctionSpec.ts#L11-L30) +> Source code: [`<>`](http://github.com/charto/readts/blob/ed8b215/src/FunctionSpec.ts#L11-L30) +> +> Methods: +> > **new( )** [FunctionSpec](#api-FunctionSpec) [`<>`](http://github.com/charto/readts/blob/ed8b215/src/FunctionSpec.ts#L14-L18) +> >  ▪ spec SymbolSpec > > Properties: > > **.name** string @@ -84,7 +92,7 @@ Docs generated using [`docts`](https://github.com/charto/docts) > > ### Class [`IdentifierSpec`](#api-IdentifierSpec) > Property, function / method parameter or variable. -> Source code: [`<>`](http://github.com/charto/readts/blob/b2ca837/src/IdentifierSpec.ts#L11-L31) +> Source code: [`<>`](http://github.com/charto/readts/blob/ed8b215/src/IdentifierSpec.ts#L11-L31) > > Properties: > > **.name** string @@ -100,10 +108,10 @@ Docs generated using [`docts`](https://github.com/charto/docts) > > ### Class [`ModuleSpec`](#api-ModuleSpec) > Module or source file. -> Source code: [`<>`](http://github.com/charto/readts/blob/5d7ba8f/src/ModuleSpec.ts#L9-L47) +> Source code: [`<>`](http://github.com/charto/readts/blob/ed8b215/src/ModuleSpec.ts#L9-L47) > > Methods: -> > **.isEmpty( )** boolean [`<>`](http://github.com/charto/readts/blob/5d7ba8f/src/ModuleSpec.ts#L30-L37) +> > **.isEmpty( )** boolean [`<>`](http://github.com/charto/readts/blob/ed8b215/src/ModuleSpec.ts#L30-L37) > >  Test if nothing is exported. > > Properties: @@ -119,13 +127,13 @@ Docs generated using [`docts`](https://github.com/charto/docts) > > ### Class [`Parser`](#api-Parser) > Main parser class with public methods, also holding its internal state. -> Source code: [`<>`](http://github.com/charto/readts/blob/b2ca837/src/Parser.ts#L34-L299) +> Source code: [`<>`](http://github.com/charto/readts/blob/ed8b215/src/Parser.ts#L35-L316) > > Methods: -> > **.parseConfig( )** ParsedCommandLine [`<>`](http://github.com/charto/readts/blob/b2ca837/src/Parser.ts#L37-L42) +> > **.parseConfig( )** ParsedCommandLine [`<>`](http://github.com/charto/readts/blob/ed8b215/src/Parser.ts#L38-L43) > >  Parse a tsconfig.json file using TypeScript services API. > >  ▪ tsconfigPath string -> > **.parse( )** [ModuleSpec](#api-ModuleSpec)[] [`<>`](http://github.com/charto/readts/blob/b2ca837/src/Parser.ts#L46-L73) +> > **.parse( )** [ModuleSpec](#api-ModuleSpec)[] [`<>`](http://github.com/charto/readts/blob/ed8b215/src/Parser.ts#L47-L74) > >  Parse a TypeScript project using TypeScript services API and configuration. > >  ▪ config ParsedCommandLine > >  ▫ nameFilter? (pathName: string) => boolean @@ -133,7 +141,7 @@ Docs generated using [`docts`](https://github.com/charto/docts) > > > ### Interface [`RefSpec`](#api-RefSpec) -> Source code: [`<>`](http://github.com/charto/readts/blob/b2ca837/src/Parser.ts#L24-L30) +> Source code: [`<>`](http://github.com/charto/readts/blob/ed8b215/src/Parser.ts#L25-L31) > > Properties: > > **.name**? string @@ -143,7 +151,13 @@ Docs generated using [`docts`](https://github.com/charto/docts) > > ### Class [`SignatureSpec`](#api-SignatureSpec) > Function or method signature defining input and output types. -> Source code: [`<>`](http://github.com/charto/readts/blob/b2ca837/src/SignatureSpec.ts#L11-L33) +> Source code: [`<>`](http://github.com/charto/readts/blob/ed8b215/src/SignatureSpec.ts#L11-L33) +> +> Methods: +> > **new( )** [SignatureSpec](#api-SignatureSpec) [`<>`](http://github.com/charto/readts/blob/ed8b215/src/SignatureSpec.ts#L14-L18) +> >  ▪ pos [SourcePos](#api-SourcePos) +> >  ▪ returnType [TypeSpec](#api-TypeSpec) +> >  ▪ doc string > > Properties: > > **.pos** [SourcePos](#api-SourcePos) @@ -156,7 +170,7 @@ Docs generated using [`docts`](https://github.com/charto/docts) > > > ### Interface [`SourcePos`](#api-SourcePos) -> Source code: [`<>`](http://github.com/charto/readts/blob/b2ca837/src/Parser.ts#L7-L11) +> Source code: [`<>`](http://github.com/charto/readts/blob/ed8b215/src/Parser.ts#L8-L12) > > Properties: > > **.sourcePath** string @@ -166,10 +180,10 @@ Docs generated using [`docts`](https://github.com/charto/docts) > > ### Class [`TypeSpec`](#api-TypeSpec) > Type definition. -> Source code: [`<>`](http://github.com/charto/readts/blob/1162bd5/src/TypeSpec.ts#L24-L123) +> Source code: [`<>`](http://github.com/charto/readts/blob/ed8b215/src/TypeSpec.ts#L24-L150) > > Methods: -> > **.format( )** string [`<>`](http://github.com/charto/readts/blob/1162bd5/src/TypeSpec.ts#L68-L109) +> > **.format( )** string [`<>`](http://github.com/charto/readts/blob/ed8b215/src/TypeSpec.ts#L95-L136) > >  Convert to string, with optional hooks replacing default formatting code. > >  ▫ hooks? [FormatHooks](#api-FormatHooks) > >  ▫ needParens? boolean