Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

This library is also available through unpkg jsDelivr, a high-performance global content delivery network built to consume npm packages.

...

Code Block
languagehtml
<!DOCTYPE html>
<html lang="en">
  <head>
    <meta charset="utf-8" />
    <title>Hawksearch Handlebars UI</title>
    <meta name="viewport" content="width=device-width, initial-scale=1" />
    <script type="text/javascript">
      var Hawksearch = Hawksearch || {};

      Hawksearch.config = {
        clientId: "f51060e1c38446f0bacdf283390c37e8"
      };
    </script>
    <script src="https://wwwcdn.unpkgjsdelivr.comnet/npm/@bridgeline-digital/hawksearch-handlebars-ui@1.0.2/dist/hawksearch-handlebars-ui.js" defer></script>
  </head>

  <body>
    <h1>Hawksearch Handlebars UI</h1>
    <hawksearch-search></hawksearch-search>
    <hawksearch-results></hawksearch-results>
  </body>
</html>
Info

It is highly recommended to target a specific version, especially if there are customizations, to avoid potentially breaking changes in the future.

For example, instead of including the script at https://wwwcdn.unpkgjsdelivr.comnet/npm/@bridgeline-digital/hawksearch-handlebars-ui/dist/hawksearch-handlebars-ui.js, you can use https://wwwcdn.unpkgjsdelivr.comnet/npm/@bridgeline-digital@1.0.0/hawksearch-handlebars-ui/dist/hawksearch-handlebars-ui.js.

Configuration

Configuration is controlled by the Hawksearch.config global object. Below is the object model used:

...