how can i create a hub object in n layer architecture
<p>currently, am working on client server application using 3 layer architecture, User interface, API and than agsxmpp Library.</p>

<p>Hubs are written in class library, I want to create the object of hub from front end. below is the script, I have included all the packages of signal r in both class library and asp.net web forms.</p>

<pre><code>&lt;script src="/signalr/signalr/hubs"&gt;&lt;/script&gt;
&lt;script type="text/javascript"&gt;
    $(function () {

        //how can I create the object of hub which exists in class library
        var connectionChat = $.connection.connectionChat;
        debugger;
    });
&lt;/script&gt;
</code></pre>

<p><a href="https://i.stack.imgur.com/m61Bt.png" rel="nofollow"><img src="https://i.stack.imgur.com/m61Bt.png" alt="how can I create hub instance in three layer architecture"></a></p>

<p><a href="https://i.stack.imgur.com/MQzPK.png" rel="nofollow"><img src="https://i.stack.imgur.com/MQzPK.png" alt="enter image description here"></a></p>