Skip to content

Commit

Permalink
Clean up project structure.
Browse files Browse the repository at this point in the history
  • Loading branch information
jjrv committed Feb 28, 2018
1 parent f7745a5 commit c857e04
Show file tree
Hide file tree
Showing 11 changed files with 29 additions and 27 deletions.
8 changes: 4 additions & 4 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,13 +2,13 @@
"name": "readts",
"version": "0.2.0",
"description": "TypeScript exported definitions parser",
"main": "dist/readts.js",
"typings": "dist/readts.d.ts",
"main": "dist/index.js",
"typings": "dist/index.d.ts",
"scripts": {
"tsc": "tsc",
"docts": "docts",
"prepublish": "tsc",
"test": "node dist/readts.js"
"test": "node dist/index.js"
},
"author": "Juha Järvi",
"license": "MIT",
Expand All @@ -22,7 +22,7 @@
"homepage": "https://github.com/charto/readts#readme",
"devDependencies": {
"@types/node": "^8.9.4",
"docts": "~0.1.0"
"docts": "~0.2.0"
},
"dependencies": {
"typescript": "^2.7.2"
Expand Down
4 changes: 2 additions & 2 deletions src/ClassSpec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,9 @@
// Released under the MIT license, see LICENSE.

import * as ts from 'typescript';
import * as readts from './readts';
import * as readts from './index';

import {SymbolSpec} from './Parser';
import { SymbolSpec } from './Parser';

/** Class or interface and its members. */

Expand Down
4 changes: 2 additions & 2 deletions src/FunctionSpec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,9 @@
// Released under the MIT license, see LICENSE.

import * as ts from 'typescript';
import * as readts from './readts';
import * as readts from './index';

import {SymbolSpec} from './Parser';
import { SymbolSpec } from './Parser';

/** Function or method with any number of overloaded signatures. */

Expand Down
4 changes: 2 additions & 2 deletions src/IdentifierSpec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,9 @@
// Released under the MIT license, see LICENSE.

import * as ts from 'typescript';
import * as readts from './readts';
import * as readts from './index';

import {SymbolSpec} from './Parser';
import { SymbolSpec } from './Parser';

/** Property, function / method parameter or variable. */

Expand Down
2 changes: 1 addition & 1 deletion src/ModuleSpec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
// Released under the MIT license, see LICENSE.

import * as ts from 'typescript';
import * as readts from './readts';
import * as readts from './index';

/** Module or source file. */

Expand Down
4 changes: 2 additions & 2 deletions src/Parser.ts
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
// This file is part of readts, copyright (c) 2016 BusFaster Ltd.
// Released under the MIT license, see LICENSE.

import * as ts from 'typescript';
import * as readts from './readts';
import * as path from 'path';
import * as ts from 'typescript';
import * as readts from './index';

export interface SourcePos {
sourcePath: string;
Expand Down
4 changes: 2 additions & 2 deletions src/SignatureSpec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,9 @@
// Released under the MIT license, see LICENSE.

import * as ts from 'typescript';
import * as readts from './readts';
import * as readts from './index';

import {SymbolSpec} from './Parser';
import { SymbolSpec } from './Parser';

/** Function or method signature defining input and output types. */

Expand Down
2 changes: 1 addition & 1 deletion src/TypeSpec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
// Released under the MIT license, see LICENSE.

import * as ts from 'typescript';
import * as readts from './readts';
import * as readts from './index';

export type FormatHook = (spec: TypeSpec, output?: string, hooks?: FormatHooks) => string;

Expand Down
10 changes: 10 additions & 0 deletions src/index.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
// This file is part of readts, copyright (c) 2016 BusFaster Ltd.
// Released under the MIT license, see LICENSE.

export { IdentifierSpec } from './IdentifierSpec';
export { SignatureSpec } from './SignatureSpec';
export { FunctionSpec } from './FunctionSpec';
export { ClassSpec } from './ClassSpec';
export { ModuleSpec } from './ModuleSpec';
export { TypeSpec, FormatHook, FormatHooks } from './TypeSpec';
export { Parser, SourcePos, RefSpec } from './Parser';
10 changes: 0 additions & 10 deletions src/readts.ts

This file was deleted.

4 changes: 3 additions & 1 deletion tsconfig.json
Original file line number Diff line number Diff line change
@@ -1,15 +1,17 @@
{
"compileOnSave": true,
"compilerOptions": {
"declaration": true,
"experimentalDecorators": true,
"module": "commonjs",
"moduleResolution": "node",
"noImplicitAny": true,
"noImplicitThis": true,
"outDir": "dist",
"removeComments": false,
"target": "es5"
},
"files": [
"src/readts.ts"
"src/index.ts"
]
}

0 comments on commit c857e04

Please sign in to comment.