ember-apply
    Preparing search index...

    Function insertText

    Public API for the html namespace

    • Add a string of HTML to an HTML document.

      Parameters

      • filePath: string
      • options: InsertBeforeFirstOptions

      Returns Promise<void>

      the before option is to insert HTML before the first tag specified -- link in this case.

      import { html } from 'ember-apply';

      await html.insertText('app/index.html', {
      text: `<link integrity="" rel="stylesheet" href="{{rootURL}}assets/tailwind.css">`,
      beforeFirst: 'link',
      });