Skip to content

Instantly share code, notes, and snippets.

View ygorluiz's full-sized avatar
🎯
Focusing

Ygor Luiz ygorluiz

🎯
Focusing
View GitHub Profile
@ygorluiz
ygorluiz / .zshrc
Last active December 12, 2024 21:01 — forked from timkinnane/.zshrc
Shell alias for PNPM install, including workspace filters.
alias p="pnpm"
alias pa="pnpm add"
alias pf="pnpm add --filter"
alias pd="pnpm add -D"
alias pdf="pnpm add -D --filter"
alias pi="pnpm i"
@ygorluiz
ygorluiz / index.html
Created November 4, 2024 16:29
Stripe-esque Nav Bar
<nav id="nav">
<ul class="navbar">
<li> Reports </li>
<li> Products </li>
<li> About </li>
</ul>
<div class="navbox">
<div class="dropdown-container">
<ul>
<li>Finance</li>
@ygorluiz
ygorluiz / bspwm.md
Created August 16, 2024 04:12 — forked from amit08255/bspwm.md
Bspwm Cheatsheet

bspwm/sxhkd cheat sheet

Common keys

@ygorluiz
ygorluiz / first-build.md
Created August 14, 2024 17:31
archlinux installation and configuration notes
@ygorluiz
ygorluiz / LC_CTYPE.md
Created August 10, 2024 17:29 — forked from nicks9188/LC_CTYPE.md
Centos warning: setlocale: LC_CTYPE: cannot change locale (UTF-8): No such file or directory
  1. vi /etc/environment

add these lines...

LANG=en_US.utf-8
LC_ALL=en_US.utf-8

Alternatively,

@ygorluiz
ygorluiz / animation.tsx
Created August 1, 2024 14:55 — forked from evertjr/animation.tsx
Feedback face animation with Framer Motion and Tailwind
"use client";
import { AnimationProps, motion } from "framer-motion";
import { useState } from "react";
type Feedbacks = "bad" | "not bad" | "good";
const feedbackMapping: { [key: number]: Feedbacks } = {
0: "bad",
1: "not bad",
@ygorluiz
ygorluiz / App.tsx
Created July 27, 2024 03:43 — forked from joaobibiano/App.tsx
Código da Vídeo sobre React com typescript
import { useState } from "react";
import "./App.css";
type TypographyProps = {
children: React.ReactNode;
size?: "small" | "large";
};
type ParagraphProps = {
color: string;
type Definition = {
vals: number[];
};
type ErrorBrand<Err extends string> = Readonly<{
[k in Err]: void;
}>;
// Entry point for our builder. Unlike the value builder
// pattern example, we don't need a definition value storing the set of
@ygorluiz
ygorluiz / index.tsx
Created July 25, 2024 06:20 — forked from bonface221/index.tsx
Framer motion animated counter up while component is in view in next js. For react remove use client and props
"use client";
import {
animate,
motion,
useInView,
useMotionValue,
useTransform,
} from "framer-motion";
import { useEffect, useRef } from "react";
@ygorluiz
ygorluiz / TypeScript.md
Created June 25, 2024 07:48 — forked from 29Kumait/TypeScript.md
Essential TypeScript Concepts for React Development

Essential TypeScript Concepts for React Development

Fundamentals

  • Types: Master basic types (string, number, boolean, etc.), arrays, tuples, and enums for robust data modeling.
  • Interfaces: Structure objects and React components with interfaces to enforce type safety, promoting code predictability.
  • Generics: Employ generics to craft reusable components and functions that seamlessly operate on various data types.

React Integration

  • Function Components: Utilize React.FC and interfaces/type aliases to precisely type component props and accurately model component behavior.
  • Hooks: Grasp the intricate typing of React hooks like useState, useReducer, and useContext to ensure state management aligns with expected data types.