Skip to content

Instantly share code, notes, and snippets.

# Basic Formatting
**bold**
*italic* (friendly)
//italic//
__underline__
~~strikethrough~~
@brecert
brecert / routes.swift
Last active September 12, 2022 14:03
struct TweetRoute: Route {
@EnviromentObject var db: Database
@Path var user: User
@Path var tweet: Tweet
var pattern: Pattern {
.GET
"user"
User.ID
"status"
const COLLIDABLE = document.getElementsByClassName('collidable')
const Direction = {
None: 0,
Left: -1,
Right: 1
}
const State = {
Walking: 0,
{
"openapi": "3.0.0",
"info": {
"title": "Revolt API",
"description": "Open source user-first chat platform.",
"termsOfService": "https://revolt.chat/terms",
"contact": {
"name": "Revolt Support",
"url": "https://revolt.chat",
"email": "contact@revolt.chat"
@brecert
brecert / context.html
Last active August 15, 2022 19:13
context menu css
<menu class="ContextMenu">
<div class="section">
<li><button>Action 1</button></li>
<li><button>Action 2</button></li>
<li><button>Action 3</button></li>
</div>
<li><button>Action 4<div class="end">bree</div></button></li>
</menu>
html {
background: radial-gradient(#e66465, #9198e5);
}
button {
font-family: "SF Pro";
}
.ActionMenu {
/* resets */
{
"a10d": [
"acknowledged",
"accomplished",
"administered"
],
"a10e": [
"architecture"
],
"a10g": [
[-
where | means to use this bind or that bind if the bind doesn't work
-]
( IO ) : import { std.lib.io }
question : ( IO ) [ prompt: String ] { IO.gets "{prompt}: " }
question : ( IO ) [ prompt: String, valid: List[String] ] {
input = IO.gets "{prompt}\n({valid.join ", "}): " .trim
{
"minecraft:charcoal": {
"id": "minecraft:charcoal",
"maxCount": 64,
"maxDamage": 0,
"translationKey": "item.minecraft.charcoal",
"isEdible": false,
"isDamageable": false,
"isEnchantable": false,
"isFireResistant": false,
<svg
width="360"
height="360"
viewBox="0 0 360 360"
version="1.1"
xmlns:xlink="http://www.w3.org/1999/xlink"
xmlns="http://www.w3.org/2000/svg"
xmlns:svg="http://www.w3.org/2000/svg"
>
<style>