I just wanted to add a few more details to the SLaks answer, which made it difficult for me to use RazorJS.
After installation using the package manager, as described here , you should add the following line to your razor:
@Html.RazorJSInclude("~/Scripts/my_javascript_file.js")
And then all your razor code will work perfectly!
Soph
source share