Skip to content

Instantly share code, notes, and snippets.

View jpalala's full-sized avatar
🔭
Lets build something useful

Joe Palala jpalala

🔭
Lets build something useful
View GitHub Profile
@jpalala
jpalala / gist:0592f349a6b9e355557a3fc24b6fd5dc
Last active September 24, 2020 04:37
intro to inertiajs

From https://reinink.ca/articles/introducing-inertia-js

I've recently abandoned server-side rendering entirely in my Laravel projects in favour of a fully Vue.js based front-end. There's a base template, which contains a single div, used as the root Vue.js container. That div has two data attributes, a component name, and component data (props). This is used to tell Vue.js which page component to display, and also provide the data (props) required for it.

<html>
<head>
    // …
@jpalala
jpalala / dst.js
Created August 19, 2020 02:15
timezone from bombay
export function getDSTOffset(dst = true) {
//DST enabled
if(dst) {
const dst_offsets = {
bombay: 5.5,
philippines: 8,
london: 1,
denver: -6,
new_york: -4
}
@jpalala
jpalala / etc_hosts.md
Created August 18, 2020 02:33
fb block

Copy this to your /etc/hosts

############################################
# To Completely Block Facebook
# Add these entries below to your hosts file
#
# Your hosts file Location:
# Linux, Unix and Mac OS X  -> /etc/hosts
# Windows XP, Vista and Windows 7 ->  C:WINDOWSsystem32driversetchosts
@jpalala
jpalala / _event-sourcing-cqrs-sample
Created August 12, 2020 03:55 — forked from justinyoo/_event-sourcing-cqrs-sample
Event Sourcing and CQRS Pattern for Angular App
This is a sample code for Event Sourcing and CQRS pattern.
* http://blog.aliencube.org/ko/2015/11/12/building-applications-on-cloud-with-event-sourcing-pattern-and-cqrs-pattern/
@jpalala
jpalala / ThrottleRequests.php
Created August 11, 2020 04:02 — forked from developerdino/ThrottleRequests.php
Lumen Middleware for rate limiting - based on Laravel's implementation.
<?php
namespace App\Http\Middleware;
use Closure;
use Illuminate\Http\Response;
use Illuminate\Cache\RateLimiter;
class ThrottleRequests
{
@jpalala
jpalala / careeradvice.md
Created June 26, 2020 02:20
Career Advice

mga sikreto ng mga nag progress

  • start initiative
  • build rapport early - lunch, team treats, kwento
  • deadlines = agreed upon specifications / commitment. learn to say No BUT..
  • there are wrong excuses and there are good excuses. make sure you're good.
  • keep learning new things
  • gary vaynerchuk - document!
  • if you have a manager or know someone senior - ask yourself - do you want to become your manager/senior in the future? alam mo na ang sagot