Mazolo
Mazolo

Reputation: 307

Using signalR in Ionic 2

In angular I can use signalR, one of the requirements is to include the following script in index.html

<script src="signalr/hubs"></script>

In ionic 2, I get the following error: Failed to load resource: net::ERR_FILE_NOT_FOUND

How do I use this with ionic 2?

Upvotes: 1

Views: 2379

Answers (2)

Mazolo
Mazolo

Reputation: 307

Using full url seems to do the trick.

Upvotes: 1

misha130
misha130

Reputation: 5736

Don't use script tags in webpack builds. The location changes and the files is not found.

For signalR in ionic I suggest you use this module

https://www.npmjs.com/package/signalr-no-jquery

Upvotes: 0

Related Questions