Skip to content

Commit

Permalink
Fix exported types
Browse files Browse the repository at this point in the history
  • Loading branch information
kristiandupont committed Nov 3, 2020
1 parent eab93c9 commit 577163a
Showing 1 changed file with 7 additions and 6 deletions.
13 changes: 7 additions & 6 deletions src/index.js → src/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -3,13 +3,14 @@ import R from 'ramda';
import extractTables from './extract-tables';
import extractTypes from './extract-types';
import extractViews from './extract-views';
import { Schema } from './types';

/**
* @param {string} schemaName
* @param {Knex} db
* @returns {Promise<import('./types').Schema>}
*/
export async function extractSchema(schemaName, db) {
export * from './types';

export async function extractSchema(
schemaName: string,
db: Knex
): Promise<Schema> {
const tables = await extractTables(schemaName, db);
const views = await extractViews(schemaName, db);
const types = await extractTypes(schemaName, db);
Expand Down

0 comments on commit 577163a

Please sign in to comment.