In Yii2 most such client related methods have been removed. Recommendation is to use separate client files for all client assets (JS/CSS). You need to be using the new View object and Assets feature for handling all client calls. This is to mainly ensure right dependencies in which client scripts will be loaded.
If you are keen, you can easily mimic the Yii1.x ajax link method by passing the ‘ajax’ property to the options array for a normal ‘Html::a’ call. Use the $view->registerJs() function to register any javascript directly on your page.
The second option is better because you can control which position the java-script call will be loaded in the view. If you have many such client scripts, its usually better to put it in one JS file and call via the AssetBundle.