Skip to content

Instantly share code, notes, and snippets.

Created November 7, 2019 15:08
What would you like to do?
import React from "react";
import useWindowSize from "./useWindowSize";
const WindowSize = () => {
const { width, height } = useWindowSize();
return (
<h2>Window size: {width} x {height}</h2>
export default WindowSize;
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment