Skip to content

Instantly share code, notes, and snippets.

View mattvague's full-sized avatar

Matt Vague mattvague

View GitHub Profile
/**
* @typedef {import('mdast').Root} Root
* @typedef {import('mdast-util-math')} DoNotTouchAsThisImportIncludesMathInTree
* @typedef Options
* @property {string} [startDelimiter=string]
* @property {string} [endDelimiter=string]
*/
import {visit, CONTINUE} from 'unist-util-visit'
import * as acorn from 'acorn'
@mattvague
mattvague / delete-dev-stores.sh
Last active February 7, 2023 01:10
Delete all shopify dev themes for a store
while read i; do echo "Deleting $i" && shopify theme delete --theme $i -f --store=[YOUR STORE NAME] ; done < <(shopify theme list --store=[YOUR STORE NAME] | awk '/Development \(.*\)/ {print $4}' | sed 's/#//')
@mattvague
mattvague / alpine-data-clash.html
Created February 27, 2024 18:30
Example of Alpine.js data clashes
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Alpine.js Example</title>
<script>
document.addEventListener('alpine:init', () => {
Alpine.directive('modal', ($el) => {