This article provides a step-by-step introduction to configure Essential JS 2 setup, build and publish a simple .NET Core web application using the Visual Studio Code (VS Code).
Starting with v16.2.0.x, if you reference to Syncfusion assemblies from trial setup or NuGet feed, you should include a license key in your projects. Refer to this link to learn about registering Syncfusion license key in your ASP.NET Core application to use the components.
The official prerequisites to create and run an ASP.NET Core 5.0 application on Windows environment are described in the .NET Core documentation website.
dotnet new mvc
Refer to here, to learn more details about
dotnet new
command line. You can run the command linedotnet new --help
, to learn more options available in the .NET CLI.
Syncfusion.EJ2.AspNet.Core
NuGet package in the project.dotnet add package Syncfusion.EJ2.AspNet.Core
Refer to here, to learn more details about the
dotnet add
command line.
~/Views/_ViewImports.cshtml
file and import the Syncfusion.EJ2
package.@addTagHelper *, Syncfusion.EJ2
<head>
element of the ~/Views/Shared/_Layout.cshtml
layout page.<head>
....
....
<!-- Syncfusion Essential JS 2 Styles -->
<link rel="stylesheet" href="https://cdn.syncfusion.com/ej2/material.css" />
<!-- Syncfusion Essential JS 2 Scripts -->
<script src="https://cdn.syncfusion.com/ej2/dist/ej2.min.js"></script>
</head>
<body>
element in the ~/Views/Shared/_Layout.cshtml
layout page.<body>
....
....
<!-- Syncfusion Essential JS 2 ScriptManager -->
<ejs-scripts></ejs-scripts>
</body>
cshtml
) in the Views
folder.For example, the calendar component is added to the ~/Views/Home/Index.cshtml
page.
<div>
<ejs-calendar id="calendar"></ejs-calendar>
</div>
Select Environment
to .NET Core
, if settings required for VS Code.
The Essential JS 2 calendar component will render in the web browser.
The official prerequisites to create and run an ASP.NET Core 3.x application on Windows environment are described in the .NET Core documentation website.
dotnet new mvc
Refer to here, to learn more details about
dotnet new
command line. You can run the command linedotnet new --help
, to learn more options available in the .NET CLI.
Syncfusion.EJ2.AspNet.Core
NuGet package in the project.dotnet add package Syncfusion.EJ2.AspNet.Core
Refer to here, to learn more details about the
dotnet add
command line.
~/Views/_ViewImports.cshtml
file and import the Syncfusion.EJ2
package.@addTagHelper *, Syncfusion.EJ2
<head>
element of the ~/Views/Shared/_Layout.cshtml
layout page.<head>
....
....
<!-- Syncfusion Essential JS 2 Styles -->
<link rel="stylesheet" href="https://cdn.syncfusion.com/ej2/material.css" />
<!-- Syncfusion Essential JS 2 Scripts -->
<script src="https://cdn.syncfusion.com/ej2/dist/ej2.min.js"></script>
</head>
<body>
element in the ~/Views/Shared/_Layout.cshtml
layout page.<body>
....
....
<!-- Syncfusion Essential JS 2 ScriptManager -->
<ejs-scripts></ejs-scripts>
</body>
cshtml
) in the Views
folder.For example, the calendar component is added to the ~/Views/Home/Index.cshtml
page.
<div>
<ejs-calendar id="calendar"></ejs-calendar>
</div>
Select Environment
to .NET Core
, if settings required for VS Code.
The Essential JS 2 calendar component will render in the web browser.
The official prerequisites to create and run an ASP.NET Core 2.x application on Windows environment are described in the .NET Core documentation website.
dotnet new mvc
Refer to here, to learn more details about
dotnet new
command line. You can run the command linedotnet new --help
, to learn more options available in the .NET CLI.
Syncfusion.EJ2.AspNet.Core
NuGet package in the project.dotnet add package Syncfusion.EJ2.AspNet.Core
Refer to here, to learn more details about the
dotnet add
command line.
~/Views/_ViewImports.cshtml
file and import the Syncfusion.EJ2
package.@addTagHelper *, Syncfusion.EJ2
<head>
element of the ~/Views/Shared/_Layout.cshtml
layout page.<head>
....
....
<!-- Syncfusion Essential JS 2 Styles -->
<link rel="stylesheet" href="https://cdn.syncfusion.com/ej2/material.css" />
<!-- Syncfusion Essential JS 2 Scripts -->
<script src="https://cdn.syncfusion.com/ej2/dist/ej2.min.js"></script>
</head>
<body>
element in the ~/Views/Shared/_Layout.cshtml
layout page.<body>
....
....
<!-- Syncfusion Essential JS 2 ScriptManager -->
<ejs-scripts></ejs-scripts>
</body>
cshtml
) in the Views
folder.For example, the calendar component is added to the ~/Views/Home/Index.cshtml
page.
<div>
<ejs-calendar id="calendar"></ejs-calendar>
</div>
Select Environment
to .NET Core
, if settings required for VS Code.
The Essential JS 2 calendar component will render in the web browser.
The official prerequisites to create and run an ASP.NET Core 1.x application on Windows environment are described in the .NET Core documentation website.
dotnet new -t web
Refer here, to learn more details about the
dotnet new
command line.
Syncfusion.EJ2
assembly reference in the dependencies
of project.json
file.
dotnet restore
Refer to here, to learn more details about
dotnet restore
command line.
~/Views/_ViewImports.cshtml
file and import the Syncfusion.EJ2
package.@addTagHelper *, Syncfusion.EJ2
<head>
element of ~/Views/Shared/_Layout.cshtml
layout page.<head>
....
....
<!-- Syncfusion Essential JS 2 Styles -->
<link rel="stylesheet" href="https://cdn.syncfusion.com/ej2/material.css" />
<!-- Syncfusion Essential JS 2 Scripts -->
<script src="https://cdn.syncfusion.com/ej2/dist/ej2.min.js"></script>
</head>
<body>
element in the ~/Views/Shared/_Layout.cshtml
layout page.<body>
....
....
<!-- Syncfusion Essential JS 2 ScriptManager -->
<ejs-scripts></ejs-scripts>
</body>
cshtml
) in the Views
folder.For example, the calendar component is added to the ~/Views/Home/Index.cshtml
page.
<div>
<ejs-calendar id="calendar"></ejs-calendar>
</div>
Select Environment
to .NET Core
, if settings required for VS Code.
The Essential JS 2 calendar component will render in the web browser.