Skip to content

Instantly share code, notes, and snippets.

View hasanuzzamanbe's full-sized avatar
👋
Hi

Hasanuzzaman Shamim hasanuzzamanbe

👋
Hi
View GitHub Profile
@hasanuzzamanbe
hasanuzzamanbe / matchAllPolyfill.js
Last active June 17, 2020 06:54
Polyfill for matchAll. example:matchAll use casse; yourString.matchAll( /your-regex/ )
// polyfill for matchAll
function matchAllPolyfill(regexPattern, sourceString) {
let output = []
let match
// make sure the pattern has the global flag
let regexPatternWithGlobal = RegExp(regexPattern, "g")
while (match = regexPatternWithGlobal.exec(sourceString)) {
delete match.input
output.push(match)
}
@hasanuzzamanbe
hasanuzzamanbe / remove-node-modules.md
Created July 2, 2019 11:45 — forked from lmcneel/remove-node-modules.md
How to remove node_modules after they have been added to a repo

How to remove node_modules

  1. Create a .gitignore file in the git repository if it does not contain one

touch .gitignore 2. Open up the .gitignore and add the following line to the file

node_modules 3. Remove the node_modules folder from the git repository

@gaearon
gaearon / index.html
Last active January 26, 2024 11:25
Add React in One Minute
<!DOCTYPE html>
<html>
<head>
<meta charset="UTF-8" />
<title>Add React in One Minute</title>
</head>
<body>
<h2>Add React in One Minute</h2>
<p>This page demonstrates using React with no build tooling.</p>
@lmcneel
lmcneel / remove-node-modules.md
Last active April 21, 2024 19:39
How to remove node_modules after they have been added to a repo

How to remove node_modules

Create a .gitignore file

  1. Check for an existing .gitignore file in the project directory
ls -a