Skip to content

Instantly share code, notes, and snippets.

View MHKarami97's full-sized avatar
:atom:
JUST DO IT

Mohammad Hossein Karami MHKarami97

:atom:
JUST DO IT
View GitHub Profile
@faustinoaq
faustinoaq / myAngular.html
Last active January 17, 2026 17:44
Front-end libraries (React, Vue, Angular) and the basic principles of how they work, all in a single file using pure JavaScript (VanillaJS).
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>My Angular from Scratch</title>
<style>
.my-component {
font-family: Arial, sans-serif;
@mberneti
mberneti / retryDynamicImport.ts
Last active September 13, 2025 07:53
This utility function retryDynamicImport enhances React’s lazy loading mechanism by adding retry logic with a versioned query parameter. It retries importing a component multiple times in case of failure, which can be useful for bypassing browser cache or dealing with intermittent network issues. It can be used as a drop-in replacement for React…
// Usage:
// Replace React.lazy(() => import('x'));
// with retryDynamicImport(() => import('x'));
import { ComponentType, lazy } from 'react';
const MAX_RETRY_COUNT = 15;
const RETRY_DELAY_MS = 500;
// Regex to extract the module URL from the import statement
@Jalalx
Jalalx / README.md
Created August 19, 2021 08:12
Set and unset Shekan DNS settings using commandline on windows

What is this?

Following scripts help you easily set DNS settings to Shekan servers and resetting them back to default.

How to use?

  1. Save following cmd files on your system.
  2. Make sure you change the "Wi-Fi" to your network adapter name
  3. Remember to run these commands as an administrator.
@RealDotNetDave
RealDotNetDave / .editorConfig
Last active February 26, 2026 11:25
.editorConfig by David (dotNetDave) McCarter - dotNetTips.com
####################################################################################################
# dotNetDave's (David McCarter) Editor Config - dotNetTips.com
# Updates to this file are posted quarterly at: https://bit.ly/EditorConfig5
# Updated January 12, 2026
# Code performance book is available at: https://bit.ly/CodePerf5
# Coding standards book is available at: https://bit.ly/CodingStandards20th
####################################################################################################
root = true
@alirezanet
alirezanet / Iran96-97.json
Last active December 11, 2025 12:52
List of provinces, states and cities of Iran with geographical coordinates (96-97 update)
[
{
"latitude": "34° 31' 24.924",
"longitude": "50° 0' 20.866",
"province": "مرکزی",
"state": "آشتیان",
"city": "آشتیان"
},
{
"latitude": "33° 40' 29.197",
@coinsandsteeldev
coinsandsteeldev / dialog.html
Last active September 8, 2024 11:18 — forked from arthurattwell/dialog.html
Google Sheets script to allow multi-select in cells with data-validation (adapted from https://www.youtube.com/watch?v=dm4z9l26O0I)
<!DOCTYPE html>
<html>
<head>
<script>
var data
var formId = 'form'
function drawForm() {
if (!data) return
var outputEl = document.getElementById(formId);
@rebornix
rebornix / logstash.conf
Created January 15, 2016 05:58
Logstash configuration for IIS log.
input {
file {
type => "IISLog"
path => "C:/inetpub/logs/LogFiles/W3SVC*/*.log"
start_position => "beginning"
}
}
filter {