Skip to content

Instantly share code, notes, and snippets.

@davidfowl
davidfowl / MinimalAPIs.md
Last active March 16, 2025 16:47
Minimal APIs at a glance
@RealDotNetDave
RealDotNetDave / .editorConfig
Last active May 1, 2025 15:51
.editorConfig by David (dotNetDave) McCarter - dotNetTips.com
####################################################################################################
# dotNetDave's (David McCarter) Editor Config - dotNetTips.com
# Updates to this file are posted quarterly at: https://bit.ly/EditorConfig5
# Updated May 1, 2025
# Code performance book is available at: https://bit.ly/DotNetCodePerf4
# Coding standards book is available at: https://bit.ly/CodingStandards8
####################################################################################################
root = true
@Coding-Enthusiast
Coding-Enthusiast / BitwiseOperations.md
Last active April 25, 2024 12:53
Bitwise operations cheat sheet

AND (&)

100  
101  
---  
100  

OR (|)

100  
101  
---  

101

@GrabYourPitchforks
GrabYourPitchforks / memory_guidelines.md
Last active January 13, 2025 17:59
Memory usage guidelines

Memory<T> usage guidelines

This document describes the relationship between Memory<T> and its related classes (MemoryPool<T>, IMemoryOwner<T>, etc.). It also describes best practices when accepting Memory<T> instances in public API surface. Following these guidelines will help developers write clear, bug-free code.

First, a tour of the basic exchange types

  • Span<T> is the basic exchange type that represents contiguous buffers. These buffers may be backed by managed memory (such as T[] or System.String). They may also be backed by unmanaged memory (such as via stackalloc or a raw void*). The Span<T> type is not heapable, meaning that it cannot appear as a field in classes, and it cannot be used across yield or await boundaries.

  • Memory is a wrapper around an object that can generate a Span. For instance, Memory instances can be backed by T[], System.String (readonly), and even SafeHandle instances. Memory cannot be backed by "transient" unmanaged me

@X-Raym
X-Raym / Highcharts Cheat Sheet.js
Created June 8, 2017 11:06 — forked from mulhoon/Highcharts Cheat Sheet
Highcharts Cheat Sheet
$('#container').highcharts({
chart: {
alignTicks: true, // When using multiple axis, the ticks of two or more opposite axes will automatically be aligned by adding ticks to the axis or axes with the least ticks.
animation: true, // Set the overall animation for all chart updating. Animation can be disabled throughout the chart by setting it to false here.
backgroundColor: '#FFF', // The background color or gradient for the outer chart area.
borderColor: '#4572A7', // The color of the outer chart border.
borderRadius: 5, // The corner radius of the outer chart border. In export, the radius defaults to 0. Defaults to 5.
borderWidth: 0, // The pixel width of the outer chart border.
className: null, // A CSS class name to apply to the charts container div, allowing unique CSS styling for each chart.
defaultSeriesType: 'line', // Alias of type.
@JimWestergren
JimWestergren / index-with-redis.php
Last active February 18, 2025 07:30
Redis as a Frontend Cache for WordPress
<?php
/*
Author: Jim Westergren & Jeedo Aquino
File: index-with-redis.php
Updated: 2012-10-25
This is a redis caching system for wordpress.
see more here: www.jimwestergren.com/wordpress-with-redis-as-a-frontend-cache/