# Reg:Socket in Ionic3

**URL:** <https://forum.ionicframework.com/t/reg-socket-in-ionic3/125502>\
**Category:** ionic-v3\
**Created:** [March 22, 2018, 10:04am UTC](https://forum.ionicframework.com/t/reg-socket-in-ionic3/125502 "2018-03-22T10:04:50Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![anandraj1411](https://avatars.discourse-cdn.com/v4/letter/a/6f9a4e/32.png) [@anandraj1411](https://forum.ionicframework.com/u/anandraj1411)\
**Post date:** [March 22, 2018, 10:04am UTC](https://forum.ionicframework.com/t/reg-socket-in-ionic3/125502/1 "2018-03-22T10:04:50Z")

</div>

I am having an issue with the socket connection with my ionic3 application. I am using socket for implementing chat. Please find the below work flow.

1. I have configured the [socket.io](http://socket.io) in my dashboard moudule (Not on app.module.ts) because I have to pass user token while connection which is obtained only after login. I have added screenshot below. Here I am getting success socket connection with the server.  
 ![Untitled](https://global.discourse-cdn.com/ionicframework/original/3X/c/0/c08d6486f8ae7c9d12e2149b4ac7de1ef25bacf8.png)

2. When I import the socket in my chat page or in any other page, I am getting the below error.  
 ![Capture](https://global.discourse-cdn.com/ionicframework/original/3X/5/f/5f89e6d23ae507e99465313696ac02911ec2b378.PNG)

Could anyone please help me how to solve this type of error?

@anna_liebt, @Sujan12 could you please help me?

---

<div class="post-metadata">

**Author:** ![mhartington](https://sea1.discourse-cdn.com/ionicframework/user_avatar/forum.ionicframework.com/mhartington/32/137757_2.png) [@mhartington](https://forum.ionicframework.com/u/mhartington)\
**Post date:** [July 19, 2021, 9:44pm UTC](https://forum.ionicframework.com/t/reg-socket-in-ionic3/125502/2 "2021-07-19T21:44:11Z")

</div>

Closed on July 19, 2021, 9:44pm UTC


