Skip to content

Instantly share code, notes, and snippets.

@tephyrnex
tephyrnex / HttpClientProgressExtensions.cs
Created February 25, 2026 17:02 — forked from dalexsoto/HttpClientProgressExtensions.cs
Add Progress reporting to capabilities to HttpClient
using System;
using System.IO;
using System.Net.Http;
using System.Threading;
using System.Threading.Tasks;
namespace HttpClientProgress {
public static class HttpClientProgressExtensions {
public static async Task DownloadDataAsync (this HttpClient client, string requestUrl, Stream destination, IProgress<float> progress = null, CancellationToken cancellationToken = default (CancellationToken))
{
@tephyrnex
tephyrnex / 0_reuse_code.js
Created March 2, 2017 14:41
Here are some things you can do with Gists in GistBox.
// Use Gists to store code you would like to remember later on
console.log(window); // log the "window" object to the console