Skip to content

Instantly share code, notes, and snippets.

View lin's full-sized avatar

Albert Lin lin

View GitHub Profile
import requests
API = "https://api.wmdb.tv/api/v1/top?type={movie_type}&skip=0&limit={limit}"
def get_top_movies(movie_type, limit=250):
r = requests.get(API.format(movie_type=movie_type, limit=limit))
if not r.ok:
raise Exception(f"Can not get movies for {movie_type} type")
return r.json()
@robpataki
robpataki / _easing-functions.scss
Last active August 10, 2022 18:51
Easing functions to be used in SCSS
// Easing function variables - http://easings.net/#easeOutQuint
// SINE
$ease-in-sine: cubic-bezier(0.47, 0, 0.745, 0.715);
$ease-out-sine: cubic-bezier(0.39, 0.575, 0.565, 1);
$ease-in-out-sine: cubic-bezier(0.445, 0.05, 0.55, 0.95);
// QUAD
$ease-in-quad: cubic-bezier(0.55, 0.085, 0.68, 0.53);
$ease-out-quad: cubic-bezier(0.25, 0.46, 0.45, 0.94);
@dmnsgn
dmnsgn / WebGL-WebGPU-frameworks-libraries.md
Last active June 25, 2024 09:41
A collection of WebGL and WebGPU frameworks and libraries

A non-exhaustive list of WebGL and WebGPU frameworks and libraries. It is mostly for learning purposes as some of the libraries listed are wip/outdated/not maintained anymore.

Engines and libraries ⚙️

Name Stars Last Commit Description
three.js ![GitHub

FWIW: I (@rondy) am not the creator of the content shared here, which is an excerpt from Edmond Lau's book. I simply copied and pasted it from another location and saved it as a personal note, before it gained popularity on news.ycombinator.com. Unfortunately, I cannot recall the exact origin of the original source, nor was I able to find the author's name, so I am can't provide the appropriate credits.


Effective Engineer - Notes

What's an Effective Engineer?

@bendc
bendc / easing.css
Created September 23, 2016 04:12
Easing CSS variables
:root {
--ease-in-quad: cubic-bezier(.55, .085, .68, .53);
--ease-in-cubic: cubic-bezier(.550, .055, .675, .19);
--ease-in-quart: cubic-bezier(.895, .03, .685, .22);
--ease-in-quint: cubic-bezier(.755, .05, .855, .06);
--ease-in-expo: cubic-bezier(.95, .05, .795, .035);
--ease-in-circ: cubic-bezier(.6, .04, .98, .335);
--ease-out-quad: cubic-bezier(.25, .46, .45, .94);
--ease-out-cubic: cubic-bezier(.215, .61, .355, 1);
@grifdail
grifdail / Input.js
Last active January 17, 2021 04:02
The best javascript input controller for game. Include gamepad support.
/*
Input.jump = {
key: 32//Space
gamepad: 0// A button on as XBOX360 gamepad
}
dont forget to call
Input.update();
at the end of each frame.
@scottdelly
scottdelly / FacebookLogin.swift
Last active April 23, 2021 21:43
Facebook Login with iOS SDK 4.0 in Swift
//If you have a Bridging-Header:
#import <FBSDKCoreKit/FBSDKCoreKit.h>
#import <FBSDKLoginKit/FBSDKLoginKit.h>
//In your AppDelegate:
func application(application: UIApplication, didFinishLaunchingWithOptions launchOptions: [String: AnyObject]?) -> Bool {
//App launch code
FBSDKApplicationDelegate.sharedInstance().application(application, didFinishLaunchingWithOptions: launchOptions)
//Optionally add to ensure your credentials are valid:
@lin
lin / 1 setup test env.md
Last active August 29, 2015 14:17
Testing

Gem file

group :development, :test do
  gem "rspec-rails"
end

group :test do
  gem "factory_girl_rails"
  gem "capybara"
 gem "guard-rspec"
@lin
lin / .bash_profile
Created November 16, 2014 15:24
Terminal Line Alias
# git alias
alias status='git status'
alias add='git add -A'
alias dev='git checkout development'
alias pushdev='git push origin development'
alias pulldev='git pull origin development'
alias commit='git commit -m'
alias push='git push origin master'
alias pull='git pull origin master'
@lin
lin / 1 setup.md
Last active August 29, 2015 14:08
Installation of a Rails app with mongoid, devise and activeadmin

1, a new rails app without active record

rails new template --skip-active-record

If you haven't installed mongoid, you should follow:

gem update --system