Any way to hook into WP after a page displays?

Thanks for the downvote. Found the answer myself anyway using the shutdown action.

What this does:

The init action clears any output buffers and starts a new one.
The Add_JS_Shortcode is added to a page and creates a location for something to be shown.
The shutdown action, from the API reference, runs just before PHP shuts down execution. It replaces the output of the shortcode with the contents of $output 30 seconds later.

The net result of this is $output ‘magically’ appears after the page is fully loaded.

It’s purpose in my case: Users enter a URL to examine on my website. Various PHP scripts run that check the Whois, fetches the header, checks for various files and directories, parses the page for details… etc. I did not want the end user staring at a browser loading symbol while these tasks were performed. This solved that problem.

 add_action('init', array($this, 'Setup_Output_Buffer'));
 add_action('shutdown', array($this, 'Shutdown_Callback' ));
 add_shortcode('Add_JS', array($this, 'Add_JS_Shortcode'));

 public function Setup_Output_Buffer() {
    $this->Clear_Buffers();
    ob_start();
 }

 public function Clear_Buffers() {
    $buffers = ob_get_status(true);
    if (count($buffers) > 1) {
        for ($i = 0; $i < count($buffers) - 1; $i++) {
            ob_end_flush();
        }
    }
 }

public function Add_JS_Shortcode($atts) {
    $output="<div id="thisdivid"></div>";
    $output .= "<script>const tobeshownlater = document.querySelector('#thisdivid');</script>";
    return $output;
}

public function Shutdown_Callback() {
   if (basename(get_permalink()) == 'pagewithshortcode') {
      sleep(30);
      $output = "This is shown 30 sec after the page loads.";
      echo '<script>tobeshownlater.innerHTML = "<div>' . $output . '</div>";</script>';
      ob_flush();
      flush();   
   }
}