Skip to content

Instantly share code, notes, and snippets.

View mslinnea's full-sized avatar
🏠
Working from home

Linnea Huxford mslinnea

🏠
Working from home
View GitHub Profile
@mslinnea
mslinnea / gutenberg-performance.php
Last active September 20, 2024 10:06
WordPress Gutenberg Performance - Disable Block Editor Preload Paths
<?php
namespace Gutenberg_Performance;
/**
* Removes the Synced Patterns (reusable blocks) from the preload paths.
* Performance improvement for sites with large number of these blocks.
*
* @param array $paths Paths.
*
@cvan
cvan / HOWTO.md
Last active December 2, 2025 21:47
get all URLs of all network requests made on a web page from the Chrome Dev Tools (from an exported HAR)

Setup

Using Homebrew on Mac OS X:

brew install jq

Add these aliases to your profile (e.g., ~/.zshrc, ~/.bashrc, ~/.profile, etc.):

alias hurlp='pbpaste | jq ".log.entries" | tee >(jq --raw-output "[.[] | .request.url] | sort | unique | .[]")'

alias hurld='pbpaste | jq ".log.entries" | jq --raw-output "[.[] | .request.url] | sort | unique | .[]" | harurls | tee >(xargs -n 1 curl -O $1)'