Skip to content

Instantly share code, notes, and snippets.

View akinncar's full-sized avatar

Akinn Rosa akinncar

View GitHub Profile
@Farhan-Haseeb
Farhan-Haseeb / README
Created June 17, 2020 16:51
How to reopen a closed PR on Github
How to reopen a pull-request from github?
Precodinitions
You need the rights to reopen pull requests on the repository.
The pull request hasn't been merged, just closed.
Go to Pull requests add filter `is:closed` choose PR you want to reopen. Select from checkbox and mark as Open.
@bajcmartinez
bajcmartinez / erc20-token-sample.sol
Last active December 17, 2024 07:15
Necessary code to generate an ERC20 Token
pragma solidity ^0.4.24;
// ----------------------------------------------------------------------------
// Sample token contract
//
// Symbol : LCST
// Name : LCS Token
// Total supply : 100000
// Decimals : 2
// Owner Account : 0xde0B295669a9FD93d5F28D9Ec85E40f4cb697BAe
@andrebrait
andrebrait / keychron_linux.md
Last active May 6, 2025 04:40
Keychron keyboards on Linux + Bluetooth fixes

Here is the best setup (I think so :D) for K-series Keychron keyboards on Linux.

Note: many newer Keychron keyboards use QMK as firmware and most tips here do not apply to them. Maybe the ones related to Bluetooth can be useful, but everything related to Apple's keyboard module (hid_apple) on Linux, won't work. As far as I know, all QMK-based boards use the hid_generic module instead. Examples of QMK-based boards are: Q, Q-Pro, V, K-Pro, etc.

Most of these commands have been tested on Ubuntu 20.04 and should also work on most Debian-based distributions. If a command happens not to work for you, take a look in the comment section.

Make Fn + F-keys work (NOT FOR QMK-BASED BOARDS)

Older Keychron keyboards (those not based on QMK) use the hid_apple driver on Linux, even in the Windows/Android mode, both in Bluetooth and Wired modes.

@sibelius
sibelius / testingConcept.md
Last active February 1, 2024 17:36
testing library concept and basic test

You first need to undestand the concept of frontend tests.

You should not test the implementation but the behavior

You test like the end user

For instance, imagine a login screen with email and password inputs and a submit button

The test should input the email and the password, then click in the submit button.

@diegomais
diegomais / script.js
Created January 31, 2021 20:43
Reverse the formatting by Intl.NumberFormat in JavaScript
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Intl.NumberFormat</title>
<script type="text/javascript" charset="UTF-8" src="script.js"></script>
</head>
<body>
<output id=output></output>
@akinncar
akinncar / reactJsLearningPath.md
Last active May 12, 2022 00:14
ReactJs Learning Path - Basics that you should learn
  • learn how to build JSX basic components
  • learn component props
  • learn how to manage state
  • learn basic hooks (useState and useEffect)
  • learn how to fetch Rest API's (Axios, SWR)
  • learn how to use routes with React Router DOM
  • learn how to manage global state (Context API, Redux, MobX)
  • learn how to make unit tests with Jest
  • learn how to use GraphQL (Apollo, Relay)
@mrousavy
mrousavy / MEMOIZE.md
Last active May 5, 2025 12:07
Memoize!!! 💾 - a react (native) performance guide
In computing, memoization or memoisation
is an optimization technique used primarily
to speed up computer programs by storing
the results of expensive function calls and  
returning the cached result when the same
inputs occur again.                                         
                                                     — wikipedia
@sibelius
sibelius / LookingForTheFirstJob.md
Last active July 3, 2023 08:48
Looking for the First Job state

Looking for the First Job

Versão em Português

This is a very common state for people in college, people before/after a bootcamp, or people from another area.

The first job will be the hardest one to get, but it will get easier over time.

The interview will be harder than the job itself

@mauriciomutte
mauriciomutte / test-utils.tsx
Last active May 7, 2021 00:31
Testing-library + styled-components + Typescript
import { ReactElement } from 'react';
import { ThemeProvider } from 'styled-components';
import { render, RenderOptions } from '@testing-library/react';
import theme from 'styles/theme';
type CustomRenderProps = Omit<RenderOptions, 'queries'>;
const customRender = (ui: ReactElement, options: CustomRenderProps = {}) =>
render(<ThemeProvider theme={theme}>{ui}</ThemeProvider>, options);
@sibelius
sibelius / reactLearningPath.md
Created May 24, 2021 01:28
React Learning Path
  • What is React props?
  • What is React state?
  • unidirectional data flow
  • how to create a React component
  • React hooks (useState, useEffect, and other basics ones)
  • Effects
  • How to handle event handlers (onClick)
  • React Context - share state for a subtree
  • Recoiljs
  • How to refactor a class component to hooks