اشتراک‌ها
ASP.NET Core و سازمان‌ها

However, it is clear that Microsoft’s future direction is in the Core space . Yes, the last update to the full .NET framework did include improvements for ASP.NET and WebForms, but clearly the future innovation and hard work will be in the new core frameworks like .NET core, ASP.NET Core, Entity Framework core, and whatever other cores come along in the future. 

ASP.NET Core و سازمان‌ها
اشتراک‌ها
کار با HubContext در ASP.NET Core SignalR

In this section, I’m going to cover how you can use SignalR outside of a Hub. In most asp.net core applications, you will likely want to communicate with the connect clients from within your application but outside of a Hub. You can accomplish this by using the HubContext.

For example, an ASP.NET Core MVC Controller or any other class that is instantiated by ASP.NET Core’s Dependency Injection.

The HubContext allows you to send messages to your connected clients. It has many of the same features to communicate with clients as when you are inside of a Hub.  

کار با HubContext در ASP.NET Core SignalR
اشتراک‌ها
NET 5.0 Preview 3. منتشر شد

Today, we’re releasing .NET 5.0 Preview 3. It contains a set of new features and performance improvements. We’re continuing to work on the bigger features that will define the 5.0 release. 

NET 5.0 Preview 3. منتشر شد
نظرات مطالب
ارتقاء به ASP.NET Core 1.0 - قسمت 1 - NET Core. چیست؟
یک نکته‌ی تکمیلی: فعال سازی Dot net core 3 در Visual Studio 2019

وقتی Visual Studio 2019  را نصب میکنید به طور پیش فرض Core 2 را دارا هست اما نسخه dote net core 3 را ندارد. برای نصب dot net core 3 ابتدا  SDK مربوطه را دانلود کنید. تا این لحظه آخرین نسخه dotnet-sdk-3.0.100-preview7-012821 می‌باشد. ممکن است برای شما نسخه جدیدتری آمده باشد. سپس آن را نصب کنید و چون نسخه  preview هست باید در visual studio 2019 آن را فعال کنید. در نسخه‌های قدیمی‌تر ویژوال استدیو 2019 ابتدا از منوی Tools مسیر زیر را دنبال کنید:
Tools > Options > Project and Solutions > .Net Core
سپس تیک مربوط به Use preview of the .NET Core SDK را قرار دهید. چنانچه این گزینه را نداشتید از مسیر زیر استفاده کنید:
Tools -> Options -> Environment -> Preview Features
حال تیک مربوط به Use preview of the .NET Core SDK را بزنید.
اکنون میتوانید پروژه خود را اجرا کنید.
اشتراک‌ها
پنجاه سایت زیبای الهام بخش که به صورت single page طراحی شده است

Here are some excellent one-page / single-page websites to check out. There are a variety of website types included in this showcase — online portfolios, restaurants, mobile apps, and more. I hope looking at these one-page sites will give you ideas and inspiration for your web design projects.

پنجاه سایت زیبای الهام بخش که به صورت single page طراحی شده است
اشتراک‌ها
بررسی تغییرات Git 2.37

Highlights from Git 2.37
The open source Git project just released Git 2.37. Take a look at some of our highlights from the latest release. 

بررسی تغییرات Git 2.37
اشتراک‌ها
افزودن هدر های امنیتی در ASP.NET Core

NetEscapades.AspNetCore.SecurityHeaders 

A small package to allow adding security headers to ASP.NET Core websites. example :   

public void Configure(IApplicationBuilder app)
{
    var policyCollection = new HeaderPolicyCollection()
        .AddFrameOptionsDeny()
        .AddXssProtectionBlock()
        .AddContentTypeOptionsNoSniff()
        .AddStrictTransportSecurityMaxAgeIncludeSubDomains(maxAgeInSeconds: 60 * 60 * 24 * 365) // maxage = one year in seconds
        .AddReferrerPolicyStrictOriginWhenCrossOrigin()
        .RemoveServerHeader()
        .AddContentSecurityPolicy(builder =>
        {
            builder.AddObjectSrc().None();
            builder.AddFormAction().Self();
            builder.AddFrameAncestors().None();
        })
        .AddCustomHeader("X-My-Test-Header", "Header value");
    
    app.UseSecurityHeaders(policyCollection);
    
    // other middleware e.g. static files, MVC etc  
}
افزودن هدر های امنیتی در ASP.NET Core
اشتراک‌ها
ویژگی Image Tag Helper در MVC 6.0
<img src="~/images/logo.png" 
     alt="company logo" 
     asp-file-version="true" />


 which will generate something like this:
<img src="/images/logo.png?v=W2F5D366_nQ2fQqUk3URdgWy2ZekXjHzHJaY5yaiOOk" 
     alt="company logo"/>

The value of the v parameter is calculated based on the contents of the image file. If the contents of the image change, the value of the parameter will change. This forces the browser to download the new version of the file, even if the old version was cached locally. This technique is often called cache busting.
ویژگی Image Tag Helper در MVC 6.0