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

Error “Type ‘EventBus’ is not generic” when using form-js-editor with Angular & TS #1153

Open
MUSTJPI opened this issue Apr 16, 2024 · 1 comment
Labels
bug Something isn't working

Comments

@MUSTJPI
Copy link

MUSTJPI commented Apr 16, 2024

Hi,

I’m using Angular 16 / "typescript": "~4.9.5", and when I import form-js-editor, I got the following compile error : “Type ‘EventBus’ is not generic”

To make it work I have to modify the following line in \node_modules@bpmn-io\form-js-editor\dist\types\features\dragging\Dragging.d.ts :

_eventBus: import(“diagram-js/lib/core/EventBus”).default<null>;

By

_eventBus: import(“diagram-js/lib/core/EventBus”).default;

OR

add “skipLibCheck” : true in tsconfig.json

But both solutions aren’t satisfying…

Thanks for your help

@MUSTJPI MUSTJPI added the bug Something isn't working label Apr 16, 2024
@MUSTJPI
Copy link
Author

MUSTJPI commented Apr 16, 2024

Didn't try, but should work :
_eventBus: import(“diagram-js/lib/core/EventBus”).default<any>;

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Development

No branches or pull requests

1 participant