Skip to content

Instantly share code, notes, and snippets.

View AliN11's full-sized avatar
😉
Focusing

Ali Nazari AliN11

😉
Focusing
View GitHub Profile
@ms-fadaei
ms-fadaei / v8-help.md
Last active December 30, 2023 08:56
V8 JavaScript engine options and flags v9.9.47

If you want to run V8 on your local machine, please use jsvu

interpreters/compilers

  • Ignition: V8 features an interpreter called Ignition. Ignition is optimized to make code run as soon as possible. Ignition converts js code to bytecode
  • Liftoff: V8 has a streaming Wasm compiler called Liftoff which, like Ignition, is geared to get your code running quickly, at the cost of generating potentially suboptimal execution speed.
  • Sparkplug: Sparkplug takes Ignition’s output (the infamous “bytecode”) and turns it into non-optimized machine code, yielding better performance at the cost of increased memory footprint.
  • TurboFan: TurboFan is one of V8’s optimizing compilers leveraging a concept called “Sea of Nodes”. Once sufficient data has been collected, TurboFan kicks in and generates low-level machine code that
@mhmda-83
mhmda-83 / excuses.json
Last active July 26, 2024 11:35
Devloper Excuses (extracted from http://developerexcuses.com/)
[
"The program has never collected that information",
"That wasn't in the original specification",
"The project manager told me to do it that way",
"There's currently a problem with our hosting company",
"Well done, you found my easter egg!",
"That feature would be outside of the scope",
"This code was not supposed to go in to production yet",
"The client must have been hacked",
"I'm still working on that as we speak",
/* Basic specificity cheatsheet */
h1 {
/* Native elements have a weight of 0001. */
}
::after {
/* Pseudo-elements have a weight of 0001. */
}
@mzpqnxow
mzpqnxow / DiscordSOCKS5.md
Created August 24, 2020 04:45
Use SOCKS5 proxy with Discord on Linux

Using SOCKS5 Proxy With Discord on Linux

You may only need the environment or the command-line parameter to force Discord to use a proxy. It doesn't hurt to use both

So if you're behind a firewall and need to go through, e.g. an SSH dynamic port forward (a SOCKS5 channel inside an SSH session) you can use the following:

$ nohup ssh -D1080 proxy_server &
$ http_proxy=socks5://127.0.0.1:1080 https_proxy=socks5://127.0.0.1:1080 /opt/Discord/Discord --proxy-server="socks5://127.0.0.1:1080"
// resources/js/services/Form.js
import FormErrors from './FormErrors'
export default class {
constructor (initialData = {}, submitCallback = null) {
this._initialData = initialData
this._submitCallback = submitCallback
this.errors = new FormErrors()
@lorisleiva
lorisleiva / readme.md
Last active December 26, 2021 13:09
Webpack aliases with Laravel Mix

Step 1: configure Webpack aliases

// webpack.mix.js

const mix = require('laravel-mix')
const path = require('path')

// ...
@lamngockhuong
lamngockhuong / ckfinder-authentication-configuration-for-laravel.md
Created February 6, 2018 16:04
[CKFinder Authentication Configuration for laravel 5] #laravel #ckfinder #ckeditor

Open and edit file 'ckfinder/config.php':

require dirname(__DIR__, 3) .'/vendor/autoload.php';
$app = require dirname(__DIR__, 3) . '/bootstrap/app.php';
$kernel = $app->make(Illuminate\Contracts\Http\Kernel::class);
$kernel->handle($request = Illuminate\Http\Request::capture());

$config['authentication'] = function () {
 if (auth()->guest()) {
@jasuperior
jasuperior / Rrray.js
Created December 26, 2017 15:24
Rrray(Relative Array): A concept using ES6 Proxies to construct a type of array whose values keep track of their sibling relationships. Also allows for circular/negative indexing.
class Rrray extends Array {
constructor(){
super(...arguments);
this.index = {}
return new Proxy(this, this.handler);
}
get handler () {
let $self = this;
return {
get(target, prop, proxy){
@nasrulhazim
nasrulhazim / AppServiceProvider.php
Last active October 1, 2023 15:47
Laravel Base64 and Base64 Image Validator
<?php
namespace App\Providers;
use Illuminate\Support\Facades\Validator;
use Illuminate\Support\ServiceProvider;
class AppServiceProvider extends ServiceProvider
{
/**
@alibo
alibo / iran-sanctions_blocker-sites.csv
Last active May 11, 2024 06:28
List of sites which block IPs come from Iran [UPDATING... (July 16, 2020)] #SANCTIONS
Title URI
Flurry by Yahoo https://dev.flurry.com/secure/signup.do
Google NikCollection https://dl.google.com/edgedl/photos/nikcollection-full-1.2.11.dmg
Bitbucket http://bitbucket.org/
SoftLayer http://softlayer.com/
VirtualBox http://download.virtualbox.org/virtualbox/5.0.16/VirtualBox-5.0.16-105871-OSX.dmg
Docker Hub https://hub.docker.com/
Oracle http://oracle.com/
Java http://java.com
Sun http://sun.com