- BUILDING A 2D AND 3D GAME FROM SCRATCH
Build a game like Pong or even one in 3D similar to Doom. You'll build your own game engine from scratch. - BUILDING A DATABASE ENGINE
Learn about the data structure behind every database engine. Building your own index mechanism for run queries faster. - BUILDING A VIRTUAL MACHINE
Learn how a CPU, a GameBoy emulator or your programming language work inside by building a virtual machine. - BUILDING A BACKEND AND FRONTEND WEB FRAMEWORK
Make a backend framework similar to Express or frontend one like Backbone. Or go wild and create something totally new. - BUILDING A NEURAL NETWORK
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Using rollup-plugin-vue |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<preview> | |
<setup | |
:requests="{ | |
// Mock requests | |
'/api/repos': $p.repeat(10, id => ({ id })), | |
'/api/repos/:id': id => $p.x.getUser(id), | |
'/api/repos/znck0': $p.http.status(404), | |
}" | |
:components="{ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/** @type {WeakMap<object, Map<any, Set<Function>>>} */ | |
const targetMap = new WeakMap() | |
let activeEffect = undefined | |
let shouldTrack = true | |
const effectStack = [] | |
const trackStack = [] | |
/** | |
* @param {object} target |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import Cocoa | |
let pasteboard = NSPasteboard.general | |
let re1 = try! NSRegularExpression(pattern: "background-color:.*?;") | |
let re2 = try! NSRegularExpression(pattern: "font-size:.*?;") | |
let re3 = try! NSRegularExpression(pattern: "font-family:.*?;") | |
let htmlType = NSPasteboard.PasteboardType(rawValue: "public.html") |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@keyframes placeHolderShimmer { | |
0% { | |
background-position: -80px 0; | |
} | |
100% { | |
background-position: 640px 0; | |
} | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
export async function forEachNonBlocking<T>( | |
arrayOrIterator: IterableIterator<T> | T[], | |
fn: (item: T) => void, | |
frameBudgetInMillis: number = 10 | |
): Promise<void> { | |
const iterator = Array.isArray(arrayOrIterator) | |
? arrayOrIterator[Symbol.iterator]() | |
: arrayOrIterator; | |
return new Promise((resolve, reject) => { |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import {promisify, CustomPromisify} from 'util' | |
export type FunctionProxy<T extends Function> = CustomPromisify<T> | |
export type PackageProxy<P extends { [key: string]: Function }> = { | |
[K in keyof P]: FunctionProxy<P[K]> | |
} | |
export function promised<T extends { [key: string]: Function | any }>(target: T): PackageProxy<T> { |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Create a module for vue component. |
NewerOlder