Skip to content

Instantly share code, notes, and snippets.

View pranjaljately's full-sized avatar

Pranjal Jately pranjaljately

View GitHub Profile
@taniarascia
taniarascia / auth.md
Last active July 5, 2024 05:43
JavaScript Authentication & Authorization Book/Course

Authentication in Real-World Web Apps with JavaScript

Outline of ideas, concepts to cover, potential projects to write.

Setup Idea

  • Book with a video for each chapter.

Prerequisites/Overview

REST APIs GraphQL
one URL serves only one request which leads to 100s of URL to maintan One URL to serves every request
Multiple roundtrip to get various kinds of data Single trip to get various combinations of data
Unwanted data travel from server to client (Wastage of bandwidth) Only required data is travelled which make response light and minimum number
No flexibility Much more flexible
Keeps Backend and frontend team tightly coupled Backend and frontend team are loosely coupled
Change in structure of APIs needs the client to change as well Change in structure of API is not needed in client side
@bradtraversy
bradtraversy / mysql_cheat_sheet.md
Last active November 15, 2024 18:40
MySQL Cheat Sheet

MySQL Cheat Sheet

Help with SQL commands to interact with a MySQL database

MySQL Locations

  • Mac /usr/local/mysql/bin
  • Windows /Program Files/MySQL/MySQL version/bin
  • Xampp /xampp/mysql/bin

Add mysql to your PATH

@bradtraversy
bradtraversy / vscode_shortcuts.md
Last active November 8, 2024 00:34
Helpful shortcuts for VSCode

VSCode Shortcuts

List of helpful shortcuts for faster coding

If you have any other helpful shortcuts, feel free to add in the comments of this gist :)

Official List of all commands

@bradtraversy
bradtraversy / docker-help.md
Last active November 15, 2024 17:06
Docker Commands, Help & Tips

Docker Commands, Help & Tips

Show commands & management commands

$ docker

Docker version info

@bradtraversy
bradtraversy / webdev_online_resources.md
Last active November 5, 2024 12:03
Online Resources For Web Developers (No Downloading)
@bradtraversy
bradtraversy / ssh.md
Last active October 22, 2024 15:35
SSH & DevOps Crash Course Snippets

SSH Cheat Sheet

This sheet goes along with this SSH YouTube tutorial

Login via SSH with password (LOCAL SERVER)

$ ssh [email protected]

Create folder, file, install Apache (Just messing around)

$ mkdir test

$ cd test

@bradtraversy
bradtraversy / myscript.sh
Last active November 9, 2024 02:10
Basic Shell Scripting
#! /bin/bash
# ECHO COMMAND
# echo Hello World!
# VARIABLES
# Uppercase by convention
# Letters, numbers, underscores
NAME="Bob"
# echo "My name is $NAME"
@wojteklu
wojteklu / clean_code.md
Last active November 15, 2024 07:19
Summary of 'Clean code' by Robert C. Martin

Code is clean if it can be understood easily – by everyone on the team. Clean code can be read and enhanced by a developer other than its original author. With understandability comes readability, changeability, extensibility and maintainability.


General rules

  1. Follow standard conventions.
  2. Keep it simple stupid. Simpler is always better. Reduce complexity as much as possible.
  3. Boy scout rule. Leave the campground cleaner than you found it.
  4. Always find root cause. Always look for the root cause of a problem.

Design rules

@wesbos
wesbos / commit-msg
Created July 4, 2016 18:55
ESLint 3.0 Git Pre Commit Hook
#!/bin/bash
files=$(git diff --cached --name-only | grep '\.jsx\?$')
# Prevent ESLint help message if no files matched
if [[ $files = "" ]] ; then
exit 0
fi
failed=0
for file in ${files}; do