Skip to content

Instantly share code, notes, and snippets.

View nazywamsiepawel's full-sized avatar
:bowtie:
hummus is life

pawel.io nazywamsiepawel

:bowtie:
hummus is life
View GitHub Profile
@ajakaja
ajakaja / smoothie.ts
Created April 20, 2020 02:09
Smoothie.ts
/*
Borrowed from https://github.com/kittykatattack/smoothie
Which is in JS, is not updated since Pixi 3, and is not on NPM.
If I get this updated I will try to submit it upstream.
Changes:
1) PIXI only
2) TilePosition and TileScale removed because it doesn't seem to exist in Pixi 5
3) MovieClip removed because it doesn't seem to exist in Pixi 5
4) refactored a bit, using arrow functions to bind this and using fewer inline functions.
@augbog
augbog / .Frontend Technical Interview Prep.md
Last active August 18, 2024 07:22
Frontend Technical Interview Prep: A study guide of things I constantly re-review when interviewing for frontend.

Frontend Technical Interview Prep

EDIT: Well this has been linked now so just an FYI this is still TBD. Feel free to comment if you have suggestions for improvements. Also here is an unrolled Twitter thread of a lot of the tips I talk about on here.

I've been doing frontend for a while now and one thing that really gripes me is the interview. I think the breadth of knowledge of a "Frontend Engineer" has been so poorly defined that people really just expected you to know everything. Many companies have made this a hybrid role. The Web is massive and there are many MANY things to know. Some of these things are just facts that you learn and others are things you really have to understand.

Every time I interview, I go over the same stuff. I wanted to create a gist of the TL;DR things that would jog my memory and hopefully yours too.

Lots of these things are real things I've been asked that caught me off guard. It's nice to have something you ca

@dyaa
dyaa / firebase.js
Last active February 10, 2024 08:58
Lazy Load Import Firebase (dynamic import)
Promise.all([
import('firebase/app'),
import('firebase/database'),
import('firebase/auth'),
])
.then(x => x[0].default)
.then(firebase => {
const config = {
apiKey: '',
authDomain: '',
@sagivo
sagivo / gist:3a4b2f2c7ac6e1b5267c2f1f59ac6c6b
Last active November 1, 2024 11:38
webRTC stun / turn server list
to check if the server works - https://webrtc.github.io/samples/src/content/peerconnection/trickle-ice
stun:
stun.l.google.com:19302,
stun1.l.google.com:19302,
stun2.l.google.com:19302,
stun3.l.google.com:19302,
stun4.l.google.com:19302,
stun.ekiga.net,
stun.ideasip.com,
@mdutkin
mdutkin / react-native-mapview AnimatedImplementation.js hack for RN0.25
Created April 28, 2016 01:18
after upgrading to react-native 0.24.1 it's broken again. in this version some new stuff was added by FB, so we can't just replace an AnimatedImplementation.js as it's suggested in README. so, this new version of AnimatedImplementation.js fixes the issue
/**
* Copyright (c) 2015-present, Facebook, Inc.
* All rights reserved.
*
* This source code is licensed under the BSD-style license found in the
* LICENSE file in the root directory of this source tree. An additional grant
* of patent rights can be found in the PATENTS file in the same directory.
*
* @providesModule AnimatedImplementation
* @flow
@thegitfather
thegitfather / vanilla-js-cheatsheet.md
Last active October 12, 2024 17:17
Vanilla JavaScript Quick Reference / Cheatsheet
@vasanthk
vasanthk / System Design.md
Last active November 14, 2024 11:31
System Design Cheatsheet

System Design Cheatsheet

Picking the right architecture = Picking the right battles + Managing trade-offs

Basic Steps

  1. Clarify and agree on the scope of the system
  • User cases (description of sequences of events that, taken together, lead to a system doing something useful)
    • Who is going to use it?
    • How are they going to use it?
@ecerney
ecerney / gist:d6bfed963eede7c685a0
Last active February 23, 2017 11:03
Guard argument
/*
* For a more in depth look at the guard statement check out
* http://ericcerney.com/swift-guard-statement/
* where I build off the sample shown here.
*/
var x: Int? = 0
// Lets me unwrap x and also check a condition on it
func fooGuard() {
@Miserlou
Miserlou / cities.json
Created April 30, 2015 06:58
1000 Largest US Cities By Population With Geographic Coordinates, in JSON
[
{
"city": "New York",
"growth_from_2000_to_2013": "4.8%",
"latitude": 40.7127837,
"longitude": -74.0059413,
"population": "8405837",
"rank": "1",
"state": "New York"
},
//
// Genetics.swift
// Genetics
//
// Created by Julius Parishy on 12/1/14.
// Copyright (c) 2014 Julius Parishy. All rights reserved.
//
import Cocoa
import CoreGraphics