ScrshotArea Component

With this component you crop screenshot to certain area. Only space between opening tag and closing tag of this component will be included in screenshot. Thanks to ScrshotArea you can focus on important part of the page. It’s additionally adding devtools where you can check what will be the size of the screenshot.


  • Only ONE component can be on page
  • Floating html elements that are outside area will be trimmed


import { defineCustomElements, ScrshotArea } from '@scrshot/react';


function Component() {
  return (
      This won't be on screenshot
        <div>This will be on screenshot</div>

Turning on/off devtools

At the bottom-left corner will be floating button mn every page where we use this component. You can click it to turn on/off scrshot devtools.