1.0.6
New in RequireJS.NET v1.0.6
RenderRequireJsSetup has a new optional param configPath, using configPath you can override the default config file.
Example of loading RequireJS.release.config when the website is running in release mode:
@using RequireJS
<!DOCTYPE html>
<html>
....
<body>
....
@if (HttpContext.Current.IsDebuggingEnabled)
{
@Html.RenderRequireJsSetup(Url.Content("~/Scripts"),
Url.Content("~/Scripts/require.js"))
}
else
{
@Html.RenderRequireJsSetup(Url.Content("~/Scripts"),
Url.Content("~/Scripts/require.js"),
Server.MapPath("~/RequireJS.release.config"))
}
</body>
</html>