Skip to content

Instantly share code, notes, and snippets.

View mjbalcueva's full-sized avatar

Mark John Balcueva mjbalcueva

View GitHub Profile
@mjbalcueva
mjbalcueva / wifi-password-retriever.md
Last active February 28, 2025 15:34
Wifi Password Retriever

WiFi Password Retriever Script

A simple one-line script that retrieves all stored WiFi network names and their passwords from a Windows system.

Usage

Command Prompt Version

for /f "tokens=2 delims=:" %i in ('netsh wlan show profiles^|findstr "All User Profile"') do @for /f "tokens=* delims= " %j in ("%i") do @(echo. & echo %j & for /f "tokens=2 delims=:" %k in ('netsh wlan show profile name^="%j" key^=clear^|findstr /C:"Key Content"') do @for /f "tokens=* delims= " %l in ("%k") do @echo %l)
@OrionReed
OrionReed / dom3d.js
Last active June 27, 2025 05:23
3D DOM viewer, copy-paste this into your console to visualise the DOM topographically.
// 3D Dom viewer, copy-paste this into your console to visualise the DOM as a stack of solid blocks.
// You can also minify and save it as a bookmarklet (https://www.freecodecamp.org/news/what-are-bookmarklets/)
(() => {
const SHOW_SIDES = false; // color sides of DOM nodes?
const COLOR_SURFACE = true; // color tops of DOM nodes?
const COLOR_RANDOM = false; // randomise color?
const COLOR_HUE = 190; // hue in HSL (https://hslpicker.com)
const MAX_ROTATION = 180; // set to 360 to rotate all the way round
const THICKNESS = 20; // thickness of layers
const DISTANCE = 10000; // ¯\\_(ツ)_/¯
@mkcode
mkcode / route.ts
Last active April 7, 2025 11:24
How to setup Next App Router + Clerk + TRPC
// TRPC API endpoint
// src/app/api/trpc/[trpc]/route.ts
import { fetchRequestHandler } from "@trpc/server/adapters/fetch";
import { type NextRequest } from "next/server";
import { env } from "~/env";
import { appRouter } from "~/server/api/root";
import { createTRPCContext } from "~/server/api/trpc";
import { getAuth } from "@clerk/nextjs/server";
@mjbalcueva
mjbalcueva / password-input.tsx
Last active June 21, 2025 12:03
shadcn ui custom password input
'use client'
import * as React from 'react'
import { EyeIcon, EyeOffIcon } from 'lucide-react'
import { Button } from '@/components/ui/button'
import { Input, type InputProps } from '@/components/ui/input'
import { cn } from '@/lib/utils'
const PasswordInput = React.forwardRef<HTMLInputElement, InputProps>(({ className, ...props }, ref) => {