Action - Body

This the action where you'll add any app content (such as a React root element). This is basically where all HTML goes that is in the body tag (minus script tags).

Example. Say I've got a React app and all I need (minus my scripts) is a single div for my app to instantiate itself:

add_action('body', function() {
echo '<div id="app"></div>';
});
view raw action-body.php hosted with ❤ by GitHub