اشتراک‌ها
کتاب Blazor- A Beginners Guide

The book covers these all-important topics:

    • What Blazor is
    • The problems it solves and how it solves them
    • Strategies for moving to Blazor from previous ASP.NET generations and JavaScript
    • Ways to get more out of Blazor by enhancing it with Telerik UI for Blazor to shorten development cycles and benefit your entire team  
کتاب Blazor- A Beginners Guide
اشتراک‌ها
مقایسه React و Angular 4

When you start working on a new web application you will probably need to analyze different tools to deal with the different functionalities that you have to work on. As soon as you start searching for alternatives you are going to run across Angular and React, they are without any doubt two of the major options to consider, at least till today.

مقایسه React و Angular 4
نظرات مطالب
رمزنگاری خودکار فیلدها توسط Entity Framework Core
 var encryptedConverter = new ValueConverter<string, string>(
               convertToProviderExpression: v => v, // How to save it: Do nothing --> Save it normally in the DB
               convertFromProviderExpression: v => new string(v.Reverse().ToArray()) // How to report it: Show it encrypted to the user
            );
بازخوردهای پروژه‌ها
Fill and FillByObject
متود زیر برای تولید عبارت مبتنی بر الگو زمانی که الگو پیچیده‌تر از این است که بشود با string.Format به راحتی پیاده سازی شود ولی چندان هم پیچیده نیست که ابزارهای حرفه ای‌تری مانند T4 یا Razor به کار بیایند، میتواند مورد استفاده قرار گیرد:
        /// <summary>
        /// Insert values from an object into a string pattern. To specify the object's property you have to use the '{propertyName}'.
        /// </summary>
        /// <remarks>
        /// This method is a replacement to String.Format, but it has two differences:
        /// <list type="simple">
        /// <item>It reverese the order you call the functionality, instead of writing String.Format(pattern, args) you write pattern.FillByObject(args). This makes the code look cleaner.</item>
        /// <item>You supply the pattern with an object and specify insertion points by property names.</item>
        /// </list>
        /// <example>
        /// <![CDATA[
        /// "First name:{firstName}, Sur name:{Surname}".FillByObject(new {firstName = "Sam", lastName="Naseri"});
        /// ]]>
        /// </example>
        /// </remarks>
        /// <seealso cref="Fill"/>
        /// <typeparam name="T">Type of bindingValue.</typeparam>
        /// <param name="bindingPattern">The pattern to fill.</param>
        /// <param name="bindingValue">The object providing values to fill in the pattern.</param>
        /// <returns>The pattern filled with values.</returns>
        public static string FillByObject<T>(this string bindingPattern, T bindingValue)
        {
            var properties = GetProperties(typeof(T)).ToList();
            var values = properties.Select(property => property.GetValue(bindingValue, new object[] { })).ToList();
            var result = bindingPattern;
            for (int index = 0; index < properties.Count; index++)
            {
                var property = properties[index];
                var propPattern = "{" + property.Name + "}";
                var old = result;
                result = result.Replace(propPattern, values[index] != null ? values[index].ToString() : "");
            }
            return result;
        }

پیاده سازی فوق یک پیاده سازی بسیار خام و بسیار کند است و جای بهبود زیادی دارد. من فقط برای سناریوهای ساده که کارایی مطرح نیست استفاده از متود فوق را توصیه میکنم.
متودهای جانبی مورد نیاز:
private static IEnumerable<PropertyInfo> GetProperties(Type t)
{
    return t.GetProperties(BindingFlags.Public | BindingFlags.Instance);
}

همچنین متود زیر هم میتواند نوشتن string.Format را یک خرده ساده‌تر کند:
/// <summary>
/// A simple replacement for String.Format which only makes the codes look nicer.
/// </summary>
/// <param name="pattern">The source string that you want to replace insertion points on it.</param>
/// <param name="args">Values to be replaced in the pattern.</param>
/// <returns></returns>
public static string Fill(this string pattern, params object[] args)
{
    return string.Format(pattern, args);
}

نظرات مطالب
استفاده از shim و stub برای mock کردن در آزمون واحد

سلام

(نوع stub همانند فریم ورک mock می‌باشد )

تعریفی که از stup تو راهنماش اومده با مطلبی که شما ذکر کردید متفاوته

Martin Fowler’s article Mocks aren’t Stubs compares and contrasts the underlying principles of Stubs and Mocks. As outlined in Martin Fowler’s article, a stub provides static canned state which results in state verification of the system under test, whereas a mock provides a behavior verification of the results for the system under test and their indirect outputs as related to any other component dependencies while under test

اشتراک‌ها
15 کتاب الکترونیکی برای طراحان و توسعه دهندگان
1.Pocket Guide to Writing SVG
2.Speaking JavaScript
3.Adaptive Web Design
4. 27 Page Type Classification eBook
5. 11 Things to Do with Every New WordPress Install
6. Building Web Apps with Go
7. Go Mobile With WordPress
8. HTML Canvas Deep Dive 
9. 10 Keys to Great Landing Pages
10. Book of Speed
11. A Practical Guide to Designing for the Web
12. PHP: The Right Way
13. Essential Career Advice for Developers
14. So You Want To Be A Freelancer?
15. Magic of CSS
15 کتاب الکترونیکی برای طراحان و توسعه دهندگان
اشتراک‌ها
18 روش خلاقانه استفاده از Docker در کارهای روزانه
18 Innovative Ways to Use Docker Daily

- Running GUI Applications in Docker Containers
- How to Run a Web Browser Inside Docker
- Using Obsidian Note-Taking App via Docker
- LibreOffice in Docker: Open-Source Office Suite Containerized
- Contribute to Science: Folding@Home with Docker
- Effortless Docker Management with Docker Desktop and Portainer
- Secure Document Handling Using Dangerzone and Docker
- Containerizing CLI Tools for a Clean System
- Enhance Docker Security with Docker Scout
- Set Up an Isolated Hacking Lab with Docker and Kali Linux
- Master Docker Networks for Container Isolation
- Automate Your Docker Workflows with Docker Compose
- Explore New Operating Systems Using Docker Containers
- Running macOS in a Docker Container (Educational Purposes)
- How to Run Raspberry Pi OS via Docker
- Access a Suite of IT Tools Inside a Docker Container
- Using Docker to Containerize AI Tools like Fabric
- Safely Test Applications with Docker Containers
- Building Custom Docker Images from Scratch
- Unconventional Docker Use Cases You Need to Know
- Daily Docker Tips and Tricks for Enhanced Productivity
- Beginner's Guide to Advanced Docker Techniques
- Boost Your IT Workflow with These Docker Hacks
- Docker for Everyday Tasks: Beyond Development
18 روش خلاقانه استفاده از Docker در کارهای روزانه
اشتراک‌ها
ایجاد یک api امن در asp.net core 3

This article will show you how to build your Web API with the new ASP.NET Core 3.0 and how to integrate with Auth0 in order to secure them. Following the steps described in this tutorial, you will end up building a simple Web API project

ایجاد یک api امن در asp.net core 3