Skip to content

Instantly share code, notes, and snippets.

@dance2die

dance2die/App Structure.js

Last active Aug 13, 2018
Embed
What would you like to do?
import React, { Component } from "react";
import ReactDOM from "react-dom";
// import debounce from "lodash.debounce";
import throttle from "lodash.throttle";
import "./styles.css";
import { getContent } from "./ContentRepo";
class App extends Component {
state = { posts: [], isBottomReached: false };
repo = getContent();
getNextPosts = async () => { ... }
throttledWindowHandler = throttle(...);
windowSizeHandler = e => { ... }
async componentDidMount() { ... }
componentWillUnmount() { ... }
loadMoreStories = () => { ... }
render() { ... }
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.