View PassData.swift
// Inspired by https://github.com/icanzilb/EventBlankApp | |
extension UIStoryboard { | |
func instantiateViewController<T: UIViewController>(_ type: T.Type) -> T { | |
return instantiateViewController(withIdentifier: type.classIdentifier) as! T | |
} | |
} | |
extension UIViewController { | |
static var classIdentifier: String { return String(describing: self) } |
View 0_reuse_code.js
// Use Gists to store code you would like to remember later on | |
console.log(window); // log the "window" object to the console |