Skip to content

Commit

Permalink
- fix for plugin option type
Browse files Browse the repository at this point in the history
  • Loading branch information
ezolenko committed Mar 10, 2020
1 parent b7c7389 commit 67748cc
Show file tree
Hide file tree
Showing 5 changed files with 11 additions and 8 deletions.
5 changes: 3 additions & 2 deletions dist/index.d.ts
Original file line number Diff line number Diff line change
@@ -1,7 +1,8 @@
import { IOptions } from "./ioptions";
import { Partial } from "./partial";
import { PluginImpl } from "rollup";
export { IOptions };
declare const typescript: PluginImpl<Partial<IOptions>>;
declare type RPT2Options = Partial<IOptions>;
export { RPT2Options };
declare const typescript: PluginImpl<RPT2Options>;
export default typescript;
//# sourceMappingURL=index.d.ts.map
2 changes: 1 addition & 1 deletion dist/index.d.ts.map

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion dist/rollup-plugin-typescript2.cjs.js.map

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion dist/rollup-plugin-typescript2.es.js.map

Large diffs are not rendered by default.

8 changes: 5 additions & 3 deletions src/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -19,9 +19,11 @@ import findCacheDir from "find-cache-dir";
import { PluginImpl, PluginContext, InputOptions, OutputOptions, TransformSourceDescription, MinimalPluginContext } from "rollup";
import { createFilter } from "./get-options-overrides";

export { IOptions }
type RPT2Options = Partial<IOptions>;

const typescript: PluginImpl<Partial<IOptions>> = (options) =>
export { RPT2Options }

const typescript: PluginImpl<RPT2Options> = (options) =>
{
let watchMode = false;
let generateRound = 0;
Expand All @@ -34,7 +36,7 @@ const typescript: PluginImpl<Partial<IOptions>> = (options) =>
let service: tsTypes.LanguageService;
let noErrors = true;
const declarations: { [name: string]: { type: tsTypes.OutputFile; map?: tsTypes.OutputFile } } = {};
const allImportedFiles = new Set();
const allImportedFiles = new Set<string>();

let _cache: TsCache;
const cache = (): TsCache =>
Expand Down

0 comments on commit 67748cc

Please sign in to comment.