I'm building an ASP.NET MVC application with a lots of jQuery ajax calls (usually to refresh lists etc.). I'm using $.load mostly. The rebinding/action js scripts are naturally in Scripts folders in .js files. At this moment I'm holding all links in _Layout.cshtml like this
var GET_ARTICLE_LIST = '@Url.Action("List","Article",null)';
var GET_FILES_LIST = '@Url.Action("Files","Library", null)';
then I'm using it in a code like this
$('.element').load(GET_ARTICLE_LIST);
is there any nicer way to pass ASP.NET MVC @Url.Action link to .js files?
console.log(GET_ARTICLE_LIST )and see what's coming there