Is it possible to interpolate my angle bracket, percent, equals <%= %> syntax in external javascript files?

后端 未结 4 1399
一生所求
一生所求 2021-02-09 23:31

Often times when mixing jQuery with asp.net I need to use asp .net angle bracket percent, <% %>, syntax within a jQuery selector.

If I would like to separate the Jav

4条回答
  •  梦毁少年i
    2021-02-10 00:12

    You could also handle .js files as .aspx files; this way you won't lose intellisense and code formatting while you're editing them. Just add this to web.config:

    
        
           
    

提交回复
热议问题