The "preferred" method is to use some sort of bouncer (znc) along with running a CLI client (irssi, weechat) in a session manager (screen, tmux) on a remote server. Weechat includes its own bouncer, and I would recommend somebody to start with it over irssi. I only fairly recently switched to weechat from znc + irssi because I wanted to try weechat.el as I wasn't happy with the state of using screen in eshell, and I don't have it as configured as my irssi was yet but I'm happy with it. Next up, switching to tmux from screen...