اشتراک‌ها
سری ویدیوهای VS Code Day 2021
Join the Visual Studio Code team and community at a live event just for VS Code users. Get a glimpse of things to come and meet the team who works on VS Code every day.
 
سری ویدیوهای VS Code Day 2021
اشتراک‌ها
15نکته‌ی مهم در مورد کروم DevTools

Google Chrome is the most popular web browser used by web developers today. With a quick six week release cycle and a powerful set of ever expanding developer features turned the browser into a must have tool. 

15نکته‌ی مهم در مورد کروم DevTools
اشتراک‌ها
استفاده از GitHub Copilot برای بهبود کیفیت کدنویسی
How to Level Up Your Coding with GitHub Copilot?

TL;DR: AI coding tools like GitHub Copilot are revolutionizing development by offering smart code suggestions, error detection, and seamless integration with popular IDEs. With 70% of developers embracing AI for increased productivity, you can boost your coding efficiency and focus on creative solutions with AI assistance.
استفاده از GitHub Copilot برای بهبود کیفیت کدنویسی
اشتراک‌ها
کتابخانه tether
A client-side library to make absolutely positioned elements attach to elements in the page efficiently. Demo
کتابخانه tether
اشتراک‌ها
PowerShell 7.1 و استفاده از NET 5.

The preview release of PowerShell 7.1 includes .NET 5 preview 1. Starting with PowerShell 7.0, devs have shifted to align with .NET’s release and support life-cycle more closely. PowerShell 7.1 is expected to become available within a week or two of .NET 5’s release date of winter 2020 and align with their annual release cadence going forward. 

PowerShell 7.1 و استفاده از NET 5.
اشتراک‌ها
ردیس ۷ در راه است

گویا ۳ برابر سریع‌تر از الستیک‌سرچ است!

In Redis 7.0, Redis Labs is adding two enhancements to its JSON support. The first is with search. RediSearch 2.0, which itself only became generally available barely a month ago; it now adds JSON as a supported data type. Before this, search was run as a separate feature that sat apart from the nodes housing the data engine. RediSearch 2.0 adds new scale-out capabilities to conduct massively parallel searches across up to billions of JSON documents across multiple nodes, returning results in fractions of a second. As the search engine was optimized for the Redis database, Redis Labs claims it runs up to 3x faster than Elasticsearch. 

ردیس ۷ در راه است
اشتراک‌ها
کتابخانه Scroll to Style

scrollToStyle is a versatile tool that lets you manage CSS properties of elements using the page scroll.
You will be able to compel the elements move, change their size, color, opacity, background and many other properties.

Features:

  • Management absolutely all the properties of a numeric value
  • Browser Support depends only on selected properties
  • It manages multiple properties of the same element
  • Management fractional property values and control the number of decimal places
  • Fixing of the screen during an animation
  • Animation range control 
کتابخانه Scroll to Style
مطالب
CoffeeScript #8

اصطلاحات عمومی CoffeeScript

Includes

برای چک کردن وجود یک مقدار در یک آرایه به طور معمول از indexOf استفاده می‌شود؛ در حالی که تمامی نسخه‌های IE به طور کامل از آن پشتیبانی نمی‌کنند.

var included = (array.indexOf("test") != -1)
CoffeeScript برای حل این مشکل، کلمه‌ی کلیدی in را ارائه کرده است:
included = "test" in array
متاسفانه برای چک کردن یک کلمه در یک متن می‌بایست از indexOf استفاده کرد و از کلمه‌ی کلیدی in نمی‌توان استفاده کرد. همچنین در صورتیکه بخواهید نبود چیزی را چک کنید نیز باید از indexOf استفاده کنید.
included = "a long test string".indexOf("test") isnt -1
و روش بهتر بجای مقایسه با مقدار 1-، استفاده از هک‌های اپراتور بیتی است:
string   = "a long test string"
included = !~ string.indexOf "test"

تکرار Propertyها

در صورتی که به خصوصیات یک شیء چندین بار نیاز داشته باشید، در جاوااسکریپت باید از کلمه‌ی کلیدی in استفاده کنید:

var object = {one: 1, two: 2}
for(var key in object) alert(key + " = " + object[key])
در حالیکه برای پیاده سازی توسط CoffeeScript باید از کلمه‌ی کلیدی of استفاده کرد:
object = {one: 1, two: 2}
alert("#{key} = #{value}") for key, value of object
نتیجه‌ی کامپایل آن می‌شود:
var key, object, value;

object = {
  one: 1,
  two: 2
};

for (key in object) {
  value = object[key];
  alert(key + " = " + value);
}
همانطور که در مثال بالا مشاهده می‌کنید، شما می‌توانید برای دسترسی به کلید و مقدار خصوصیات موجود در شیء، متغیری را برای هر کدام تعریف کنید که ما در اینجا از key  و value استفاده کرده‌ایم.

Min/Max

درست است که این تکنیک مخصوص CoffeeScript نیست، اما اشاره به آن می‌تواند مفید باشد. تابع Math.max و Max.min می‌توانند چندین آرگومان یا یک آرایه را به عنوان ورودی گرفته و بر روی آن محاسبات خود را انجام داده و خروجی را نشان دهند:

Math.max [14, 35, -7, 46, 98]... # 98
Math.min [14, 35, -7, 46, 98]... # -7
نتیجه‌ی آن پس از کامپایل می‌شود:
Math.max.apply(Math, [14, 35, -7, 46, 98]);

Math.min.apply(Math, [14, 35, -7, 46, 98]);
نکته: در صورتیکه آرگومان‌ها یا تعداد خانه‌های آرایه ارسالی زیاد باشند، چون مرورگرها محدودیتی را در تعداد پارامترهای ارسالی به یک تابع دارند، خروجی تولید نخواهد شد.

اشتراک‌ها
بررسی C# 7

Jon Skeet presents some of the features coming in C# 7 - tuples, pattern matching, local functions, throw expressions, numeric literals, and more – along with hints regarding future versions.  

بررسی C# 7