I use Webstorm editor and I work with Angular 15. I get the following message for subscribe function : "Deprecated symbol used" I found this post and on the rxjs site that the method has changed: Angular 11: subscribe is deprecated: Use an observer instead?
So i have updated my code :
test() {
// Recommended
this.backendServices.getAllBox().subscribe(
(response) => {
console.log(response);
},
(error) => {
console.log(error);
},
() => {
console.log('complete');
}
);
}
But the message is still present :

Then I found on google that this error can be produced by tslint and it is recommended to convert tslint by eslint. It's what I do by following this tuto :https://www.google.com/search?q=how+to+change+tslint+to+eslint&newwindow=1&sca_esv=582242121&rlz=1C1CHBF_frFR843FR843&sxsrf=AM9HkKkuhEYk7LWdKCbD7df9l3CiseljJA%3A1699960850354&ei=ElhTZeybFeK6kdUPtr2K-AM&oq=how+to+change+tslin&gs_lp=Egxnd3Mtd2l6LXNlcnAiE2hvdyB0byBjaGFuZ2UgdHNsaW4qAggAMgYQABgWGB4yCBAAGBYYHhgKMgYQABgWGB4yBhAAGBYYHkj7eVAAWJtocAF4AZABAJgBuwGgAccUqgEEMC4yMLgBA8gBAPgBAcICBBAjGCfCAgcQIxiKBRgnwgILEAAYgAQYsQMYgwHCAhEQLhiDARjHARixAxjRAxiABMICCxAuGIAEGMcBGK8BwgIOEC4YgAQYsQMYgwEY1ALCAgsQLhiDARixAxiKBcICCxAAGIoFGLEDGIMBwgIFEAAYgATCAhEQLhiABBixAxiDARjHARjRA8ICBRAuGIAEwgIIEC4YgAQYsQPCAggQABiABBixA8ICCBAuGIAEGNQCwgIIEAAYigUYsQPCAhcQLhiABBixAxiXBRjcBBjeBBjgBNgBAcICCRAAGA0YExiABMICBxAAGBMYgATCAggQABgWGB4YE-IDBBgAIEGIBgG6BgYIARABGBQ&sclient=gws-wiz-serp#fpstate=ive&vld=cid:8749a8e7,vid:fsr6CFqqsLc,st:0
Angular.json et package.json have been updated as following :

But the error is still present.
What is missing ?
EDIT: my getAllBox method:
getAllBox() {
return this.http.get<ApiResponse>(this.apiUrl + '/api/site/all');
}

Its just the calling signature of subscribe which is deprecated.
instead of:
you should use the current recommended way:
From Observable.ts:
personal view:
For the most cases i just use the subscribe signature only with the next callback, for errors i use the
catchErroroperator for complete i usefinalize