Purpose
Find all property detail page URLs represented in Fairbourne's portfolio section.
When to Use
Use when the caller needs the Fairbourne portfolio's property-page links, optionally with the visible property names.
Workflow
- Navigate directly to
https://www.fairbourne.com/. - In one page evaluation after the portfolio gallery has rendered, run this extractor:
(() => {
const origin = location.origin;
const seen = new Set();
return [...document.querySelectorAll(".wixui-gallery__item a[href]")]
.map((a) => ({
title: a.innerText.trim().replace(/\s+/g, " "),
url: new URL(a.getAttribute("href"), origin).href,
}))
.filter(
(x) =>
x.url.startsWith(origin + "/") &&
x.url !== origin + "/" &&
!seen.has(x.url) &&
seen.add(x.url),
);
})();Return the resulting array of {title, url} objects; the url values are the property detail page URLs.
Site-Specific Gotchas
- Fairbourne's portfolio is rendered as a Wix gallery; the durable gallery-item selector is
.wixui-gallery__item a. - The gallery may render asynchronously. Run the evaluation after the page's gallery content is present; do not assume the initial HTML snapshot contains every item.
- Resolve relative links against
location.originand deduplicate URLs because gallery markup can contain repeated anchors. - This recipe intentionally scopes extraction to portfolio gallery items rather than collecting unrelated navigation links.
Expected Output
An array of unique objects of the form { "title": "<property name>", "url": "https://www.fairbourne.com/<property-path>" }.