- Apollo GrpahQL allows a simplified way of building a server with GraphQL. It also allows you do the data binding in various technical stacks using Apollo packages on client side applications.
- GraphQL follows schema first design requiring to think of data in terms of graphs
- In a graph, nodes represent objects, where as arrows (edges) represent relationships
This file contains hidden or 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
// What would be the outcome of this statement? | |
const [a, b] = [10, 20]; | |
This file contains hidden or 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
Show hidden characters
{ | |
"New Component Boilerplate": { | |
"prefix": "component", | |
"body": [ | |
"import React from 'react';", | |
"import PropTypes from 'prop-types';", | |
"import styles from './$1.module.$2css';", | |
"", | |
"export default function $1({ $2 }) {", | |
" return (", |
Say you have 12 commits on a few files for a branch that has not been reviewed yet
Here is a way to make it look like a better, cleaner story:
$ git rebase -i HEAD~12 #number of commits you have on your branch
# In editor window, replace all `pick` options for commits with `squash` or `s`
# Hit escape and write `:wq` and hit enter
This file contains hidden or 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
[filter "lfs"] | |
clean = git-lfs clean -- %f | |
smudge = git-lfs smudge -- %f | |
required = true | |
[push] | |
default = current | |
[alias] | |
a = add | |
cm = commit -m | |
co = checkout |
I hereby claim:
- I am dhruv-m-patel on github.
- I am dhruvpatel (https://keybase.io/dhruvpatel) on keybase.
- I have a public key ASDtrCjDw_Vrkxb4AJDkqGGXuETidn76EHCUDiL-IuUE5wo
To claim this, I am signing this object:
This file contains hidden or 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
// Generic abstraction of web storage operations available for local and session storage | |
function Storage(storage) { | |
this.moment = require('moment'); | |
this.store = storage; | |
} | |
Storage.prototype = { | |
cache: function(key, value, ttl) { | |
if(!value || !this.store) { | |
return; | |
} |
This file contains hidden or 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
.simple-pagination { | |
display: inline-block; | |
padding-left: 0; | |
margin-top: 1rem; | |
margin-bottom: 1rem; | |
border-radius: .25rem; | |
} | |
.simple-pagination li { | |
display: inline; | |
} |