Skip to content

Instantly share code, notes, and snippets.

View alissonmarcs's full-sized avatar

Alisson alissonmarcs

  • São Bernardo do Campo, São Paulo, Brasil
  • 12:48 (UTC -03:00)
  • LinkedIn in/alissonmarcs
View GitHub Profile
<!-- component -->
<div class="min-h-screen flex items-center justify-center bg-gray-100 py-6">
<div class="flex w-full max-w-xs p-4 bg-gray-800">
<ul class="flex flex-col w-full">
<li class="my-px">
<a href="#"
class="flex flex-row items-center h-12 px-4 rounded-lg text-gray-600 bg-gray-100">
<span class="flex items-center justify-center text-lg text-gray-500">
<svg fill="none"
stroke-linecap="round"
@Gustavo-Kuze
Gustavo-Kuze / ngrok_free_multi_tunnels.md
Created October 7, 2020 21:44
Executar múltiplos túneis NGROK

Para configurar o ngrok para rodar tanto o projeto frontend quanto o backend simultaneamente, basta adicionar o seguinte código ao arquivo "C:\Users\USER\.ngrok2\ngrok.yml"

authtoken: 1bGvuFnqnXjihKbkqtx8qVld2ie_2736j4KfrDdMHhBh3uDtn
tunnels:
  portafront:
    proto: http
    addr: 8000
  portaapi:
 proto: http
@superjojo140
superjojo140 / cors-fetch-express.md
Last active July 9, 2025 21:02
CORS fetch-request with credentials

This sounds easy but... it isn't!

Client side

Use this fetch options:

fetch('superUnsecureCorsUrl',{
   credentials: 'include'
})
@john-raymon
john-raymon / authentication-on-the-web-cheat-sheet.md
Last active July 8, 2025 19:48
Authentication on the Web (Sessions, Cookies, JWT, localStorage, and more)

Authentication

  • authentication: verifying identity (401 Unauthorized)
  • authorization: verifying permissions (403 Forbidden)

Username/password scheme

  • stateful/session-based/cookie-based (i.e. session using a cookie)
  • stateless/token-based (i.e. token using JWT / OAuth / other)
@fayazara
fayazara / gender.vue
Created April 24, 2020 04:33
Tailwind css grid with in action
<template>
<section class="grid grid-cols-2 gap-2 mb-6">
<div class="rounded-md shadow-md bg-gray-800 p-4 w-full">
<svg
class="w-16 h-16 mx-auto"
fill="currentColor"
stroke="currentColor"
viewBox="0 0 384 384"
>
<path
@BjornDCode
BjornDCode / gist:5cb836a6b23638d6d02f5cb6ed59a04a
Created February 3, 2020 11:58
Tailwind - Fixed sidebar, scrollable content
// Source: https://twitter.com/calebporzio/status/1151876736931549185
<div class="flex">
<aside class="h-screen sticky top-0">
// Fixed Sidebar
</aside>
<main>
// Content
</main>
@Hakky54
Hakky54 / openssl_commands.md
Last active July 28, 2025 02:28 — forked from p3t3r67x0/openssl_commands.md
OpenSSL Cheat Sheet

OpenSSL Cheat Sheet 🔐

Install

Install the OpenSSL on Debian based systems

sudo apt-get install openssl
@tsprates
tsprates / binary-tree.c
Last active October 27, 2024 10:09
A Binary Tree implementation in C
// Binary Tree
// Author: Thiago Prates <[email protected]>
#include <stdio.h>
#include <stdlib.h>
typedef struct _node {
int data;
struct _node* left;
struct _node* right;
@straker
straker / README.md
Last active August 1, 2025 21:23
Basic Pong HTML and JavaScript Game

Basic Pong HTML and JavaScript Game

This is a basic implementation of the Atari Pong game, but it's missing a few things intentionally and they're left as further exploration for the reader.

Further Exploration

  • Score
  • When a ball goes past a paddle, the other player should score a point. Use context.fillText() to display the score to the screen

Everything I Know About UI Routing

Definitions

  1. Location - The location of the application. Usually just a URL, but the location can contain multiple pieces of information that can be used by an app
    1. pathname - The "file/directory" portion of the URL, like invoices/123
    2. search - The stuff after ? in a URL like /assignments?showGrades=1.
    3. query - A parsed version of search, usually an object but not a standard browser feature.
    4. hash - The # portion of the URL. This is not available to servers in request.url so its client only. By default it means which part of the page the user should be scrolled to, but developers use it for various things.
    5. state - Object associated with a location. Think of it like a hidden URL query. It's state you want to keep with a specific location, but you don't want it to be visible in the URL.