Skip to content
This repository has been archived by the owner on Jan 6, 2023. It is now read-only.

Not working in angular 15. Error: Failed to initialize Angular compilation - Failed to compile entry-point @stomp/ng2-stompjs #268

Open
badalpatelhops opened this issue Nov 22, 2022 · 1 comment

Comments

@badalpatelhops
Copy link

Hi, recently I have upgrade my ionic/angular project into angular version 15 from angular 14

In angular 14 working as Aspected. but after upgrading to angular 15 getting the error below
Error: Failed to initialize Angular compilation - Failed to compile entry-point @stomp/ng2-stompjs

error NG2006: The injectable RxStompService inherits its constructor from RxStomp, but the latter does not have an Angular decorator of its own.

I think the error getting because of angular 15 changes in the Dependency Injection link attached below

https://angular.io/guide/update-to-version-15#invalid-constructors-for-dependency-injection-can-report-compilation-errors

image

@kum-deepak
Copy link
Member

The Angular compilation process has changed significantly in the past few releases. Because of that, it is no longer possible to maintain a single version of this library that works across all versions.

So, my recommendation will be to use rx-stomp directly. Please follow the guide at https://stomp-js.github.io/guide/rx-stomp/ng2-stompjs/ng2-stompjs-to-rx-stomp.html

In the very near future, this library will be deprecated in favor of rx-stomp.

Let me know if it helps.

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

No branches or pull requests

2 participants