<? $this->registerJsFile('@web/user/js/jquery.formstyler.js', ['depends' => [yii\web\JqueryAsset::className()]]); ?>
It is highly recommended to use asset bundles to register external JS files rather than registerJsFile() because these allow better flexibility and more granular dependency configuration. Also using asset bundles allows you to combine and compress multiple JS files, which is desirable for high traffic websites.