Module 4 - Unit 2

I believe in this section the code has a slight bug in it.

You need to import

SandboxEndpoints

from

@yext/search-headless-react

or your code will error. Hope this helps someone else!

update

import {
  provideHeadless,
  Environment,
  SearchHeadlessProvider,
  SandboxEndpoints,   // ADD THIS LINE
} from "@yext/search-headless-react";

Also I believe the quiz may have an issue in question one as it asks about the location order the search returns, but that may be updating over time so the question may have become stale.

Hi Hunter - great catch! We are updating that code block in the unit, as well as updating the first question of that quiz.

Thanks,
Katja

I don’t see the point on adding a deprecated import like that one:

Screenshot 2024-06-11 101939

Hi @Kenny_Quinones,

You no longer need this import, given the PagesJS 1.0 update, but it was needed at the time Hunter posted.

1 Like