Add An 'async' Attribute To A Js Include Tag In Asp.net Web Forms
I saw how it can be done in MVC, but for a specific project I'm using Web-Forms. I have <%: System.Web.Optimization
Solution 1:
You can use RenderFormat to achieve this:
<%: System.Web.Optimization.Scripts.RenderFormat ("<scriptsrc='{0}'async ></script>", "~/file.js") %>
Renders as: <script src="/file.js" async=""></script>
Post a Comment for "Add An 'async' Attribute To A Js Include Tag In Asp.net Web Forms"