Skip to content

Instantly share code, notes, and snippets.

View assadk88's full-sized avatar

Assad Khan assadk88

View GitHub Profile
@Jimmant91
Jimmant91 / tutorial.md
Last active August 11, 2021 09:27
Regex Tutorial

Regex Tutorial: Matching an HTML Tag

A regex, which is short for regular expression, is a sequence of characters that defines a specific search pattern. When included in code or search algorithms, regular expressions can be used to find certain patterns of characters within a string, or to find and replace a character or sequence of characters within a string. They are also frequently used to validate input.

Summary

This Regex tutorial will breakdown the regular expression that can be used to search for tags, and potentially extract the data, in an HTML document, using the following string of code:

/^<([a-z]+)([^<]+)*(?:>(.*)<\/\1>|\s+\/>)$/

@arthurdapaz
arthurdapaz / Setting_upa_new_repo.md
Last active November 7, 2020 15:21 — forked from alexpchin/Setting_upa_new_repo.md
Create a new repository on the command line

Setting up a new Git Repo

##Create a new repository on the command line

REPO="REPO_NAME_HERE"
curl -u 'USER' https://api.github.com/user/repos -d '{"name":"$REPO"}'
touch README.md

git init

@joelhsmith
joelhsmith / lh-config-a11y-extras.js
Last active November 15, 2023 22:46
Custom Lighthouse config with all a11y audits and a few from Best Practices and SEO that are accessibility related.
/**
* Lighthouse custom config file for running A11y audits in Lighthouse.
* Includes all a11y audits and a few from Best Practices and SEO that are accessibility related.
* Organized into custom 'groups'
*
* Run:
lighthouse https://cats.com --config-path=/path/to/this/file/lh-config-a11y-extras.js --disable-device-emulation --output=json --output-path=catsaudit.json --chrome-flags="--headless --window-size=1300,600"
*
*/
module.exports = {
@ncochard
ncochard / babel-webpack.md
Last active April 2, 2025 18:22
The correct way to compile ES6 using babel...

When you create a npm package, remember it might be used in a browser or a server, or even a command line utility… For each package you create, please pay attention at what it will be used for:

  1. Is it going to be used as a dependency to a nodejs application that is not bundled? (e.g. command line utilities)
  2. Is it going to be used as a dependency to a nodejs application that is bundled? (e.g. AWS Lambdas)
  3. Is it going to be used as a dependency to a browser application (always bundled)?.
  • In cases 2) and 3) you want to allow for tree shaking.
  • In cases 1) and 2) you want to benefit from the "ES6"/"ES next" features supported natively by nodejs.
  • In case 3) you also want to benefit from the native support of "ES6" from your browser.
@MWins
MWins / project-ideas01.md
Last active October 12, 2025 09:43
Back end Projects - list

Project Ideas

Ok. I'm going to list off some ideas for projects. You will have to determine if any particular idea is good enough to include in a portfolio. These aren't creative ideas. They likely already exist. Some are way too advanced while others are simplistic.

I will recommend to post any project you make to github and make a github project page for it. Explain in as much detail as possible how you made it, how it can be improved etc. Document it.

If you pick an advanced idea, setup a development roadmap and follow it. This will show some project management skills.

Another piece of advice for those who are design challenged. Use different front end frameworks and use different themes for those frameworks to provide appealing designs without looking like yet another bootstrap site.

@vasanthk
vasanthk / System Design.md
Last active October 22, 2025 09:01
System Design Cheatsheet

System Design Cheatsheet

Picking the right architecture = Picking the right battles + Managing trade-offs

Basic Steps

  1. Clarify and agree on the scope of the system
  • User cases (description of sequences of events that, taken together, lead to a system doing something useful)
    • Who is going to use it?
    • How are they going to use it?
@iangreenleaf
iangreenleaf / gist:b206d09c587e8fc6399e
Last active September 5, 2025 19:33
Rails naming conventions

Rails naming conventions

General Ruby conventions

Class names are CamelCase.

Methods and variables are snake_case.

Methods with a ? suffix will return a boolean.

Rich Hickey on becoming a better developer

Rich Hickey • 3 years ago

Sorry, I have to disagree with the entire premise here.

A wide variety of experiences might lead to well-roundedness, but not to greatness, nor even goodness. By constantly switching from one thing to another you are always reaching above your comfort zone, yes, but doing so by resetting your skill and knowledge level to zero.

Mastery comes from a combination of at least several of the following:

@ihower
ihower / gist:442a6d6fd968534996b8
Last active April 1, 2021 12:21
ALPHA Camp Web Development Bootcamp #3 Syllabus (draft)