Skip to content

Instantly share code, notes, and snippets.

@serkanince
Last active May 17, 2016 11:32
Show Gist options
  • Save serkanince/deab63369b89b700c6bd76feae9e332b to your computer and use it in GitHub Desktop.
Save serkanince/deab63369b89b700c6bd76feae9e332b to your computer and use it in GitHub Desktop.
Bundle Örnek 2
public class MvcApplication : System.Web.HttpApplication
{
protected void Application_Start()
{
AreaRegistration.RegisterAllAreas();
RouteConfig.RegisterRoutes(RouteTable.Routes);
BundleConfig.RegisterBundles(BundleTable.Bundles); //Bu satırı ekliyoruz.
}
}
// Burası Önemli -> referans eklenmesi gerekir.
@using System.Web.Optimization;
<!DOCTYPE html>
<html lang="en">
<head>
<title>Bundle Örnek </title>
@Styles.Render("~/bundles/Css")
</head>
<body>
//Örnek olarak
@Scripts.Render("~/bundles/Js")
</body>
</html>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment