Skip to main content

HeadManager

The HeadManager class is used for working with document head tags on the server. On a server-side render it collects all the document head tags and renders them as a string.

import { HeadManager } from '@archibald/client';

// Create a new instance.
const manager = new HeadManager();

// Add a tag to internal list of tags.
manager.add(TAG);

// Render list of tracked tags to a string.
manager.render();