src/jsCallback.php
public function terminate($ajaxec, $msg = null, $success = true)
    {
        $this->app->terminate(json_encode(['success' => $success, 'message' => $msg, 'atkjs' => $ajaxec]));
    }
public function terminate($ajaxec, $msg = null, $success = true)
    {
        $this->app->terminate(json_encode(['success' => $success, 'message' => $msg, 'atkjs' => $ajaxec]));
    }
public function terminate ( $ ajaxec , $ msg = null , $ success = true ) { $ this -> app -> terminate ( json_encode ( [ 'success' => $ success , 'message' => $ msg , 'atkjs' => $ ajaxec ] ) ) ; }
A proper way to finish execution of AJAX response. Generates JSON
which is returned to frontend.

@param array|jsExpressionable $ajaxec  Array of jsExpressionable
@param string                 $msg     General message, typically won't be displayed
@param bool                   $success Was request successful or not

@return [type] [description]
A proper way to finish execution of AJAX response . Generates JSON which is returned to frontend .