Skip to content

Instantly share code, notes, and snippets.

View MarlonPassos-git's full-sized avatar

Marlon Passos MarlonPassos-git

View GitHub Profile
@MarlonPassos-git
MarlonPassos-git / obsidian_plugin.json
Last active June 27, 2026 21:14
Obsidian Plugin Manifest
{
"$schema": "http://json-schema.org/draft-07/schema#",
"title": "Obsidian Theme Manifest",
"description": "Schema for Obsidian theme manifest.json files",
"type": "object",
"required": ["name", "version", "minAppVersion", "author"],
"properties": {
"name": {
"type": "string",
"description": "Display name of the theme as shown in the UI",
@MarlonPassos-git
MarlonPassos-git / README.md
Last active July 30, 2026 07:58
grill-me-codex

grill-me-codex

Small Codex skills for better planning with request_user_input.

This is a tiny adaptation of the grill-me workflow for Codex.

The goal is simple: make Codex ask better planning questions before writing code, without forcing you into a heavier workflow like a full spec system.

Why

@MarlonPassos-git
MarlonPassos-git / useEventListener.ts
Created March 13, 2025 21:12
react hook useUserIteration.ts
/* eslint-disable @typescript-eslint/ban-ts-comment */
import type { RefObject } from "react";
import { useEffect, useRef } from "react";
import { useIsomorphicLayoutEffect } from "./useIsomorphicLayoutEffect";
type NewEvent = "storageUpdate" | "local-storage";
// MediaQueryList Event based useEventListener interface
function useEventListener<K extends keyof MediaQueryListEventMap>(
@MarlonPassos-git
MarlonPassos-git / terminal.sh
Last active November 10, 2024 21:34
Config VSCode finditfaster dependecies
#!/bin/bash
mkdir temp1
cd temp1
# Instalar fzf
git clone --depth 1 https://github.com/junegunn/fzf.git ~/.fzf
~/.fzf/install --all
# Instalar ripgrep
wget https://github.com/BurntSushi/ripgrep/releases/download/13.0.0/ripgrep-13.0.0-x86_64-unknown-linux-musl.tar.gz
@MarlonPassos-git
MarlonPassos-git / keybinding.json
Last active November 10, 2024 20:23
VSCode config
// Coloque as suas associações de teclas neste arquivo para substituir os padrõesauto[]
[
{
"key": "alt+e",
"command": "HookyQR.beautifyFile"
},
{
"key": "ctrl+1",
"command": "workbench.action.openEditorAtIndex1"
},
import type { FC, ReactElement } from 'react'
import { useEffect, useState } from 'react'
interface DomContentInterface {
children: ReactElement<any, any> | null
}
const DOMContentLoadedWrapper: FC<DomContentInterface> = ({ children }) => {
const [isReady, setIsReady] = useState(false)
@MarlonPassos-git
MarlonPassos-git / tsconfig.json
Created May 2, 2023 20:13
tsconfig to: nodejs, typescript, ESM, import json files
{
"compilerOptions": {
"target": "ES2022",
"module": "ESNext",
"lib": ["ES2022"],
"moduleResolution": "node",
"resolveJsonModule": true,
"allowSyntheticDefaultImports": true,
"allowJs": true,
"outDir": "dist"
@MarlonPassos-git
MarlonPassos-git / instalar_cypress_wsl2.md
Created March 28, 2023 13:55 — forked from J-Pster/instalar_cypress_wsl2.md
Como instalar o Cypress no WSL2 (+ Puppeteer)

Instalando o Cypress no WSL 2 (+ Usando o Puppeteer em testes)

Depois de muito tempo sofrendo, finalmente descobri como instalar o Cypress de forma limpa e tranquila no WSL2, e vou te ensinar, e além disso, quando você instalar aqui o Cypress, testes que usam o Puppeteer que é a mesma dependência que o Cypress usa, também passarão a rodar no seu WSL2!

Esse tutorial é muito útil se você está tendo o erro error while loading shared libraries: libgbm.so.1: cannot open shared object file: No such file or directory ou algo parecido!

Créditos ao autor original, nesse link!

Antes de executar qualquer comando, ou código que eu tenha deixado aqui, tenta primeiro entender o que está escrito, e para os .sh, dê uma lida neles, mesmo que eu diga que seja seguro, é sempre bom olhar!

@MarlonPassos-git
MarlonPassos-git / index.js
Last active March 9, 2023 14:40
blocks translation of code blocks on the web
// ==UserScript==
// @name New Userscript
// @namespace http://tampermonkey.net/
// @version 0.1
// @description try to take over the world!
// @author You
// @match *://*/*
// @grant none
// ==/UserScript==
@MarlonPassos-git
MarlonPassos-git / debounce.js
Created October 21, 2022 01:32
debounce with cancel and return
const debounce = (
{ delay },
func
) => {
let timer= null
let c = true
function debounced (...args) {
if (c) {
clearTimeout(timer)
timer = setTimeout(() =>{