This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import { useCallback, useEffect, useRef, useState } from "react"; | |
interface UseBroadcastChannelOptions { | |
name: string; | |
onMessage?: (event: MessageEvent) => void; | |
onMessageError?: (event: MessageEvent) => void; | |
} | |
interface UseBroadcastChannelReturn<D, P> { | |
isSupported: boolean; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Security audit | |
on: | |
schedule: | |
- cron: '0 0 * * *' | |
push: | |
paths: | |
- '**/Cargo.toml' | |
- '**/Cargo.lock' | |
jobs: | |
security_audit: |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/opt/homebrew/bin/python3 | |
import re | |
import glob | |
import os | |
import graphviz | |
################################################################################## | |
######### USAGE ######### |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package main | |
import ( | |
"bytes" | |
"fmt" | |
"io" | |
"os" | |
) | |
const flagStart = `-----{% start %}-----` |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
collection_id = '...' # -99 to empty trash | |
token = '...' | |
from requests import Session | |
session = Session() | |
session.headers = { | |
'Authorization': f'Bearer {token}' | |
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/opt/bin/python3 | |
import os | |
import requests | |
question_id = os.environ.get('KMVAR_LeetCodeID', 'add-two-numbers').strip() | |
cookies={ | |
"LEETCODE_SESSION": '' | |
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/opt/bin/python3 | |
# pip install markdownify | |
import os | |
import requests | |
question_id = os.environ.get('KMVAR_LeetCodeID', 'add-two-numbers').strip() | |
cookies={ |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/opt/bin/python3 | |
# pip install markdownify | |
import os | |
import requests | |
import markdownify | |
question_id = os.environ.get('KMVAR_LeetCodeID', 'add-two-numbers') |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
div[placeholder~="Heading"]::after { | |
margin-left: 0.5em; | |
font-size: 0.6em; | |
vertical-align: middle; | |
opacity: 0.7; | |
} | |
div[placeholder="Heading 1"]::after { | |
content: "h1"; | |
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
set -e | |
echo Build All | |
echo Build for linux | |
(CGO_ENABLED=0 GOOS=linux ./build.sh) | |
echo Build for windows | |
(CGO_ENABLED=0 GOOS=windows ./build.sh) |
NewerOlder