Sign inConnect your agent
breakingchangedShopify calls it: Action Required

currententrychange now returns the previous page in event.from for customer account full-page extensions

Announced
Tags
Customer-Account-API, Customer-Accounts
Severity
breaking, set by reef/rss-rule-v1
Source
https://shopify.dev/changelog/currententrychange-now-returns-the-previous-page-in-event-from-for-customer-account-full-page-extensions

Starting in API version 2027-01, in customer account full-page extensions the Navigation API currententrychange event sets event.from to the page the customer navigated away from, instead of the page they navigated to. This is a breaking change for customer account full-page extensions that read the new page from event.from. Update them to read shopify.navigation.currentEntry before you move them to 2027-01.

What changed

In customer account full-page extensions (customer-account.page.render and customer-account.order.page.render), currententrychange passes a NavigationCurrentEntryChangeEvent whose from property is documented as the previous history entry. In API version 2026-10 and earlier, from is the new entry instead, the same value as shopify.navigation.currentEntry. Starting in 2027-01, from is the previous entry.

Who's affected

Full-page extensions on API version 2027-01 or later that use event.from to find the page the customer navigated to are affected.

Extensions on 2026-10 and earlier aren't affected, because their behavior doesn't change. Extensions that read shopify.navigation.currentEntry, including extensions that use the useNavigationCurrentEntry hook, aren't affected on any version.

Breaking changes and migrations

On 2027-01, code that reads the new page from event.from.url gets the previous page's URL instead. For example, an extension that chooses which route to render from event.from keeps showing the previous route after each navigation.

Replace those reads with shopify.navigation.currentEntry.url.

Before:

shopify.navigation.addEventListener('currententrychange', (event) => {
  setPath(new URL(event.from.url).pathname);
});

After:

shopify.navigation.addEventListener('currententrychange', () => {
  setPath(new URL(shopify.navigation.currentEntry.url).pathname);
});

The updated code works on API version 2025-10 and later, so you can make the change before you update your API version.

Action required

Before you update a customer account full-page extension to 2027-01, update every currententrychange handler that reads the new page from event.from. To confirm the update, navigate between two routes in your extension and check that each navigation shows the page you navigated to.

Related docs

The text above is the source's. reef added the severity, the dates it could read from the text, and the endpoints and scopes named in code.