This file contains 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
{ | |
"name": "flask-react-infinite", | |
"version": "1.0.0", | |
"description": "Flask React Infinite Scroll Tutorial", | |
"main": "index.js", | |
"scripts": { | |
"build": "webpack -p --progress --config webpack.config.js", | |
"dev-build": "webpack --progress -d --config webpack.config.js", | |
"test": "echo \"Error: no test specified\" && exit 1", | |
"watch": "webpack --progress -d --config webpack.config.js --watch" |
This file contains 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 AppBar from '@material-ui/core/AppBar'; | |
import Toolbar from '@material-ui/core/Toolbar'; | |
/*...*/ | |
const useStyles = makeStyles((theme) => ({ | |
/*...*/ | |
smallProfileImage: { | |
width: theme.spacing(5), |
This file contains 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
<!--...--> | |
<script type="text/javascript"> (function() { var css = document.createElement('link'); css.href = 'https://use.fontawesome.com/releases/v5.1.0/css/all.css'; css.rel = 'stylesheet'; css.type = 'text/css'; document.getElementsByTagName('head')[0].appendChild(css); })(); </script> | |
<!--...--> |
This file contains 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 Fade from '@material-ui/core/Fade'; | |
import Slide from '@material-ui/core/Slide'; | |
/*...*/ | |
export default function Header() { | |
/*...*/ | |
return ( | |
/*...*/ |
This file contains 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, useEffect } from 'react'; | |
/*...*/ | |
export default function Header() { | |
const [small, setSmall] = useState(false); | |
function handleScroll() { | |
const distanceY = window.pageYOffset || document.documentElement.scrollTop, | |
shrinkOn = 250; |
This file contains 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 Accordion from "@material-ui/core/Accordion"; | |
import AccordionSummary from "@material-ui/core/AccordionSummary"; | |
import AccordionDetails from "@material-ui/core/AccordionDetails"; | |
import ExpandMoreIcon from "@material-ui/icons/ExpandMore"; | |
/*...*/ | |
import SocialIcon from './SocialIcons'; | |
/*...*/ |
This file contains 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 Container from "@material-ui/core/Container"; | |
import Avatar from "@material-ui/core/Avatar"; | |
import Typography from "@material-ui/core/Typography"; | |
import makeStyles from "@material-ui/core/styles/makeStyles" | |
import { Data } from './data'; |
This file contains 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
export const Data = { | |
'name': 'Spencer Porter', | |
'username': 'spencer.porter', | |
'bio': 'Test', | |
'image': 'https://offbrand-img.s3.amazonaws.com/jR/71226EA1-D8C8-474C-9464-FE72AB0E779B%2B(2)%20(1).jpeg', | |
"social":[{ | |
"id":"jR", | |
"social_name":"facebook", | |
"url":"https://facebook.com/spencer.porter2" | |
},{ |
This file contains 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 .. import db, cache | |
#... | |
from ..utils import make_cache_key | |
#... | |
@main.route('/link') | |
@cache.cached(key_prefix=make_cache_key, timeout=60) | |
def get_link(): | |
#... |
NewerOlder