Skip to content

Instantly share code, notes, and snippets.

View kitloong's full-sized avatar

Kit Loong kitloong

  • Rakuten
  • Kuala Lumpur, Malaysia
View GitHub Profile
@kitloong
kitloong / js-shorthand-ternary.md
Last active November 30, 2020 07:19
JS shorthand ternary
let variable1 = null
console.log(variable1 || false) // false

variable1 = true
console.log(variable1 || false) // true

variable1 = false
console.log(variable1 || false) // false
<?php
namespace App\Console\Commands;
use Illuminate\Console\Command;
use Illuminate\Database\Schema\Grammars\MySqlGrammar;
use Illuminate\Database\Schema\Grammars\PostgresGrammar;
use Illuminate\Database\Schema\Grammars\SQLiteGrammar;
use Illuminate\Database\Schema\Grammars\SqlServerGrammar;
use Illuminate\Support\Fluent;
@kitloong
kitloong / mac-homebrew-lamp.md
Last active April 27, 2024 06:56
Mac - Install Apache, PHP, MySQL + phpMyAdmin with Homebrew

!!! This guide was created with Macbook Pro M1. Path may vary for different or even same machine.

Install Homebrew

/bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install.sh)"

Install PHP