Skip to content

Instantly share code, notes, and snippets.

import { marked, Renderer } from "https://esm.sh/marked@4.2.12";
async function fetchMarkdownFromGithub(repoOwner, repoName, filePath) {
const fileUrl = `https://raw.githubusercontent.com/${repoOwner}/${repoName}/${filePath}`;
const response = await fetch(fileUrl);
if (!response.ok) {
throw new Error(`Error fetching Markdown file: ${response.statusText}`);
}
return await response.text();
}
function createMarkdownToHtmlConverter(repoOwner, repoName) {
<html>
<head>
<link rel="stylesheet" type="text/css" href="https://esm.sh/monaco-editor@0.34.1/min/vs/editor/editor.main.css"/>
</head>
<body>
<h1>Hello World</h1>
<div id="container" style="width: 800px; height: 600px; border: 1px solid #ccc"></div>
</body>
<script type="module">
import * as monaco from 'https://esm.sh/monaco-editor@0.34.1';
#!/usr/bin/env bash
# Add to your ~/.zshrc or ~/.profile
# source: https://gist.github.com/mob-sakai/174a32b95572e7d8fdbf8e6f43a528f6
gist() {
GIST_URL=$1
if [[ ! $GIST_URL ]]; then
echo -e "\nGIST_URL is required\n"
else
shift
{
"lume3d": [{
"type": "script",
"attributes": {
"src": "https://unpkg.com/lume@0.3.0-alpha.9/dist/global.js"
}
},
{
"type": "script",
"attributes": {
{
"nav": "0f142ffa935850569a0a05e0b8064322",
"footer": "94d242d29c7b63a67acf96b64053f2ac",
"routes": {
"/": "a5a50ed1011bf5e9e2ab8941dab6cc30",
"/about": "4c7ad16e312a29f0079a226b886e5016"
},
"webComponents": "bc5c6697a30f413643c8529875037123"
}
const div = document.createElement("div");
div.style.padding = "2rem";
div.style.display = "flex";
div.style.justifyContent = "space-between";
div.style.maxWidth = "700px";
const button = document.createElement("button");
const colors = ["indigo", "purple", "gold", "khaki", "aqua"];
function getRandomColor() {
return colors[Math.floor(Math.random()*colors.length)];
import React from "https://esm.sh/react";
export default function ClientModule() {
return (
<section>
<h2>Client Module A</h2>
<p>TODO: put interactive JS stuff in this component</p>
<button onClick={() => alert("hello this button is interactive!")}>
do something
</button>
<h1>About</h1>
<p>Very busy 🐇. No time to explain, Arseniy.</p>
<div h-screen text-center flex select-none all:transition-400>
<div ma>
<!--
<div
text-5xl
fw100
animate-bounce-alt
animate-count-infinite
animate-duration-1s
>
<h1>Gist Quilt</h1>
<p>
Using Deno to piece together a quilt of GitHub Gists into a single HTML page.
</p>