Skip to content

Instantly share code, notes, and snippets.

View Zadigo's full-sized avatar
🌴
On vacation

John PENDENQUE Zadigo

🌴
On vacation
View GitHub Profile
@Zadigo
Zadigo / countries.json
Created April 21, 2022 21:48 — forked from keeguon/countries.json
A list of countries in JSON
[
{name: 'Afghanistan', code: 'AF'},
{name: 'Åland Islands', code: 'AX'},
{name: 'Albania', code: 'AL'},
{name: 'Algeria', code: 'DZ'},
{name: 'American Samoa', code: 'AS'},
{name: 'AndorrA', code: 'AD'},
{name: 'Angola', code: 'AO'},
{name: 'Anguilla', code: 'AI'},
{name: 'Antarctica', code: 'AQ'},
@Zadigo
Zadigo / html-tags.json
Last active January 17, 2023 21:16 — forked from cecchi/html-tags.json
["html","base","head","style","title","address","article","footer","header","h1","h2","h3","h4","h5","h6","hgroup","nav","section","dd","div","dl","dt","figcaption","figure","hr","li","main","ol","p","pre","ul","abbr","b","bdi","bdo","br","cite","code","data","dfn","em","i","kbd","mark","q","rp","rt","rtc","ruby","s","samp","small","span","strong","sub","sup","time","u","var","wbr","area","audio","map","track","video","embed","object","param","source","canvas","noscript","script","del","ins","caption","col","colgroup","table","tbody","td","tfoot","th","thead","tr","button","datalist","fieldset","form","input","keygen","label","legend","meter","optgroup","option","output","progress","select","details","dialog","menu","menuitem","summary","content","element","shadow","template","acronym","applet","basefont","big","blink","center","dir","frame","frameset","isindex","listing","noembed","plaintext","spacer","strike","tt","xmp","body","a","textarea","svg","plygon","path","img","link"]
export function useDebounce() {
function debounce<T extends (...args: any[]) => void>(func: T, wait: number, immediate: boolean = false) {
let timeout: ReturnType<typeof setTimeout> | null = null
// return function (this: any, ...callbackArgs: Parameters<T>) {
return function (...callbackArgs: Parameters<T>) {
// const context = this
function later() {
timeout = null
@Zadigo
Zadigo / advanced_leveinstein_calculator.py
Last active February 3, 2025 15:40
A simple Python module that calculates the distance between two words
import re
from difflib import SequenceMatcher
import random
import Levenshtein
from rapidfuzz import fuzz, process
from thefuzz import fuzz as thefuzz
import pandas
from unidecode import unidecode
# https://www.datacamp.com/tutorial/fuzzy-string-python
@Zadigo
Zadigo / estlint.config.mjs
Last active May 7, 2025 15:56
Base vite configuration files
import globals from 'globals'
import eslint from '@eslint/js'
import eslintPluginVue from 'eslint-plugin-vue'
import typescriptEslint from 'typescript-eslint'
import stylistic from '@stylistic/eslint-plugin'
export default typescriptEslint.config(
{
ignores: [
'*.d.ts',