Answers powered article tiles

Usage:

To initialise the answers experience app on an external site, you need to have the main script loaded

      <script src="https://design-system.yext.com/dist/js/main.js"></script>
      

Once the script is loaded, you can call initAnswersArticleTiles, which accepts 4 arguments:

  1. ID DOM selector (string): This is the container where the app will be injected
  2. ID DOM selector (string): This is the element/section that the page will scroll to after new pagination link is clicked
  3. Vertical Key (string): The key to the vertical (e.g.: "case_studies", "resources"). Falls back to "case_studies"
  4. Input (string): The search input (e.g.: "food", "healthcare", "retail")

    <script>
      DesignSystem.main.initAnswersArticleTiles({
        container: "#answers-article-tiles",
        scrollTo: "#answers-article-tiles-section",
        verticalKey: "case_studies",
        input: "food",
      });
    </script>