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
#Copyright 2021 Fabian Bosler | |
# Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation | |
# files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, | |
# modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom | |
# the Software is furnished to do so, subject to the following conditions: | |
# The above copyright notice and this permission notice shall be included in all copies or substantial portions of the | |
# Software. |
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 dash | |
import os | |
import plotly.express as px | |
import pandas as pd | |
import dash_core_components as dcc | |
import dash_bootstrap_components as dbc | |
import dash_html_components as html | |
import json | |
from urllib.request import urlopen | |
from dash.dependencies import Input, Output |
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
const express = require("express"); | |
const router = express.Router(); | |
const passport = require("passport"); | |
const config = require("../config/config"); | |
const providerScopes = { | |
google: { scope: ["profile", "email"] }, | |
facebook: { scope: ["email"] }, | |
amazon: { scope: ["profile"] }, | |
github: {}, |
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
from datetime import datetime | |
import aiohttp | |
import asyncio | |
URL = "https://medium.fabianbosler.de/run" | |
async def sample_asyncio(samples): | |
start = datetime.now() |
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
from functools import lru_cache | |
from datetime import datetime | |
@lru_cache(maxsize=None) | |
def fib_cache(n): | |
if n < 2: | |
return n | |
return fib_cache(n-1) + fib_cache(n-2) | |
def fib_no_cache(n): |
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 React, { useState } from "react"; | |
import { Modal, Form, Col, Row } from "react-bootstrap"; | |
import axios from "axios"; | |
import DelegatedAuthList from "../DelegatedAuthList"; | |
import { | |
PaddedContainer, | |
EmailSymbol, | |
PasswordSymbol, | |
ResponsiveHeader4, |
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 { Navbar } from "react-bootstrap"; | |
import styled from "styled-components"; | |
export const StyledFooter = styled(Navbar)` | |
background-color: white; | |
-webkit-box-shadow: 0 24px 38px 3px #f7f7f72e, 0 9px 46px 8px #ffffff2b, 0 11px 15px -7px #ffffff45; | |
box-shadow: 0 24px 38px 3px #f7f7f72e, 0 9px 46px 8px #ffffff2b, 0 11px 15px -7px #ffffff45; | |
border-top: 2px solid #114b74; | |
`; |
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 React from "react"; | |
import { Link } from "react-router-dom"; | |
import { StyledFooter } from "./styles"; | |
const Footer = () => { | |
return ( | |
<StyledFooter sticky="bottom"> | |
<div style={{ float: "left" }}>© 2020 Copyright: Fabian Bosler</div> | |
<div style={{ float: "right", marginLeft: "auto" }}> | |
<Link to="/about">About</Link> <Link to="/about">Impressum</Link> |
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 React from "react"; | |
import { BrowserRouter as Router, Route } from "react-router-dom"; | |
import Landing from "./components/layout/Landing"; | |
import About from "./components/layout/About"; | |
import Profile from "./components/layout/Profile"; | |
import Nav from "./components/layout/Nav"; | |
import "bootstrap/dist/css/bootstrap.min.css"; | |
const App = () => { |
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 { Navbar } from "react-bootstrap"; | |
import styled from "styled-components"; | |
export const StyledNav = styled(Navbar)` | |
background-color: white; | |
-webkit-box-shadow: 0 24px 38px 3px #f7f7f72e, 0 9px 46px 8px #ffffff2b, 0 11px 15px -7px #ffffff45; | |
box-shadow: 0 24px 38px 3px #f7f7f72e, 0 9px 46px 8px #ffffff2b, 0 11px 15px -7px #ffffff45; | |
border-bottom: 2px solid lightgrey; | |
`; |