Skip to content

Instantly share code, notes, and snippets.

🏠
Working from home

Arup Rakshit aruprakshit

🏠
Working from home
Block or report user

Report or block aruprakshit

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
View vim
" snippets
Plug 'SirVer/ultisnips'
Plug 'atefth/ruby-on-rails-snippets-vs-code'
Plug 'abusaidm/html-snippets'
Plug 'wvffle/vimterm'
Plug 'mtdl9/vim-log-highlighting'
Plug 'vim-ruby/vim-ruby'
Plug 'joker1007/vim-ruby-heredoc-syntax'
Plug 'chase/vim-ansible-yaml'
View everything-i-know-about-routing.md

Everything I Know About UI Routing

Definitions

  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.
View App.Combobox.js
/* eslint-disable jsx-a11y/accessible-emoji */
import React, { Suspense, useState } from "react";
import { unstable_scheduleCallback } from "scheduler";
import { unstable_createResource as createResource } from "react-cache";
import {
Combobox,
ComboboxInput,
ComboboxList,
ComboboxOption,
ComboboxOptionText
@azer
azer / fake-chat.elm
Created May 21, 2018
Elm Ports Example
View fake-chat.elm
port module FakeChat exposing (..)
import Html exposing (Html, div, input, text, button, ul, li)
import Html.Events exposing (onClick, onInput)
import Html.Attributes exposing (type_, placeholder, value)
main =
Html.program
{ view = view
@robertgonzales
robertgonzales / Frame.js
Created Dec 12, 2017
Use React portals to render inside shadow dom and iframes
View Frame.js
class Frame extends Component {
componentDidMount() {
this.iframeHead = this.node.contentDocument.head
this.iframeRoot = this.node.contentDocument.body
this.forceUpdate()
}
render() {
const { children, head, ...rest } = this.props
return (
@heygrady
heygrady / mapDispatchToProps.md
Last active Dec 6, 2019
Redux containers: mapDispatchToProps
View mapDispatchToProps.md

Redux containers: mapDispatchToProps

This document details some tips and tricks for creating redux containers. Specifically, this document is looking at the mapDispatchToProps argument of the connect function from [react-redux][react-redux]. There are many ways to write the same thing in redux. This gist covers the various forms that mapDispatchToProps can take.

View asm-setup.md
@kyledcline
kyledcline / postgres-best-practices.md
Last active Dec 12, 2019
Postgres Best Practices
View postgres-best-practices.md

PSQL CLI Client

Psql is a fully-fledged CLI client for Postgres, but most people are unaware of its many advanced features.

~/.psqlrc can be edited to persist any behavior or configuration settings you want between psql sessions. It behaves just like ~/.bashrc or ~/.vimrc, sourced at psql launch. See More out of psql for some interesting configurations.

If you have a long query to write and rewrite, you can use \e to edit your query in an editor.

Use \watch at the end of a query in order to automatically re-run the query every few seconds - great for monitoring while making changes elsewhere in your application architecture.

View react-firebase-setup.md

React && Firebase Workshop

Contact Information

Prequisite Setup

  • A recent version of Node.js
  • npm install -g create-react-app
You can’t perform that action at this time.