Skip to content

Instantly share code, notes, and snippets.


Puneeth Shetty shettypuneeth

View GitHub Profile
mmrko / mocha-react-css-modules.js
Last active Dec 28, 2018
Mocha & React & CSS Modules with Sass
View mocha-react-css-modules.js
// setup.js
import hook from 'css-modules-require-hook'
import sass from 'node-sass'
extensions: [ '.scss' ],
preprocessCss: data => sass.renderSync({ data }).css
aVolpe / EmbeddedGist.js
Created Sep 13, 2016
EmbeddedGist allows a gist to be embedded in a React application
View EmbeddedGist.js
import React, { Component } from 'react';
class EmbeddedGist extends Component {
constructor(props) {
this.gist = props.gist;
this.file = props.file;
this.stylesheetAdded = false;
this.state = {

Everything I Know About UI Routing


  1. Location - The location of the application. Usually just a URL, but the location can contain multiple pieces of information that can be used by an app
    1. pathname - The "file/directory" portion of the URL, like invoices/123
    2. search - The stuff after ? in a URL like /assignments?showGrades=1.
    3. query - A parsed version of search, usually an object but not a standard browser feature.
    4. hash - The # portion of the URL. This is not available to servers in request.url so its client only. By default it means which part of the page the user should be scrolled to, but developers use it for various things.
    5. state - Object associated with a location. Think of it like a hidden URL query. It's state you want to keep with a specific location, but you don't want it to be visible in the URL.
gokulkrishh / media-query.css
Last active Apr 22, 2021
CSS Media Queries for Desktop, Tablet, Mobile.
View media-query.css
##Device = Desktops
##Screen = 1281px to higher resolution desktops
@media (min-width: 1281px) {
/* CSS */
vasanthk / System
Last active Apr 23, 2021
System Design Cheatsheet
View System

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?
staltz /
Last active Apr 23, 2021
The introduction to Reactive Programming you've been missing