Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

--flow-typed-format doesn't work #60

Open
4rokis opened this issue Oct 25, 2018 · 3 comments
Open

--flow-typed-format doesn't work #60

4rokis opened this issue Oct 25, 2018 · 3 comments

Comments

@4rokis
Copy link

4rokis commented Oct 25, 2018

Running

$ flowgen --flow-typed-format build/focus.d.ts
Parsing focus
Missing node parse ExportDeclaration

Doesn't produce any output file.
However,

$ flowgen build/focus.d.ts
Parsing focus
Missing node parse ExportDeclaration

does.

declare type FakeEventType = {
keyCode: number,
preventDefault(): void
};
export type KeyDownEventType = {
key: number,
target?: HTMLElement,
originalEvent: KeyboardEvent | FakeEventType | MouseEvent
};
declare var focus: (toFocus: string) => void;
declare var fakeKeyDown: (fakeEvent: FakeEventType) => boolean;
declare var fakeEnter: () => boolean;
declare var fakeReturn: () => boolean;

$ flowgen -V
1.3.0

focus.d.ts

declare type FakeEventType = {
keyCode: number;
preventDefault(): void;
};
export declare type KeyDownEventType = {
key: number;
target?: HTMLElement;
originalEvent: KeyboardEvent | FakeEventType | MouseEvent;
};
declare const focus: (toFocus: string) => void;
declare const fakeKeyDown: (fakeEvent: FakeEventType) => boolean;
declare const fakeEnter: () => boolean;
declare const fakeReturn: () => boolean;
export { focus, fakeKeyDown, fakeEnter, fakeReturn };
//# sourceMappingURL=focus.d.ts.map

@goodmind
Copy link
Contributor

goodmind commented Feb 8, 2019

I think it works

@goodmind
Copy link
Contributor

goodmind commented Feb 8, 2019

It just doesn't support directory name

@goodmind
Copy link
Contributor

Fixed in #73

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants