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
# A multiline prompt with username, hostname, full path, return status, git branch, git dirty status, git remote status | |
local return_status="%{$fg[red]%}%(?..⏎)%{$reset_color%}" | |
local host_color="green" | |
if [ -n "$SSH_CLIENT" ]; then | |
local host_color="red" | |
fi | |
PROMPT=' |
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
{"lastUpload":"2021-07-24T17:12:08.176Z","extensionVersion":"v3.4.3"} |
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
import { | |
Elm | |
} from './Main.elm' | |
import './main.css' | |
import firebase from "firebase" | |
import gun from "gun" | |
const app = Elm.Main.init({ | |
node: document.getElementById('main') |
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
document.arrive("#chartContainer", (elem) => { | |
if(elem.dataset.type == "bar") | |
drawBarChart() | |
else | |
drawPieChart() | |
}) |
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
view : Model -> Html Msg | |
view model = | |
let | |
renderSvg which = | |
div [ HA.id "chartContainer", HA.attribute "data-type" which ] | |
[ svg [ HA.id "bar", HA.width 700, HA.height 500 ] [] ] | |
in | |
div [] | |
[ button [ onClick (ShowChart BarChart), disabled (model.chart /= NoChart) ] [ Html.text "Show Bar Chart" ] | |
, button [ onClick (ShowChart PieChart), disabled (model.chart /= NoChart) ] [ Html.text "Show Pie Chart" ] |
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
module Main exposing (Model, Msg(..), extractRepoResponse, fetchRepos, getRepos, init, main, update, view) | |
import Browser | |
import Dict | |
import Html exposing (..) | |
import Html.Attributes exposing (..) | |
import Html.Events exposing (..) | |
import Http | |
import Json.Decode as Decode | |
import Json.Decode.Pipeline as Pipeline |
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
type Msg | |
= GotRepos (Result Http.Error RepoResponse) | |
type alias RepoResponse = | |
( List LinkHeader.WebLink, List Repo ) | |
fetchRepos : Cmd Msg | |
fetchRepos = |
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
> curl -I https://api.github.com/users/girishso/repos | |
. | |
. | |
Link: <https://api.github.com/user/35009/repos?page=2>; rel="next", <https://api.github.com/user/35009/repos?page=2>; rel="last" | |
. | |
. |
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
module Main exposing (..) | |
import RemoteData exposing (WebData, RemoteData(..), asCmd, fromTask) | |
import Html exposing (Html, text, div, input, br) | |
import Html.Events exposing (onClick) | |
import Html.Attributes exposing (type_, value) | |
import Http exposing (get, toTask) | |
import Json.Decode exposing (Decoder, string) | |
import Json.Decode.Pipeline exposing (decode, required) | |
import Random exposing (int, generate) |
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
module BottomScroll exposing (main) | |
import InfiniteScroll as IS | |
import Html exposing (..) | |
import Html.Attributes exposing (style) | |
import Http | |
import Json.Decode as JD | |
type Msg |
NewerOlder