How to share components among multiple extensions?

Hello! This is my first time working with Shopify Plus and its architecture. My goal is to customize the new customer account area with several pages.

  1. I have created and installed an app.

  2. In the app, I’ve created “Customer account UI extensions” of the type “Full-page extension,” specifically using customer-account.page.render (I’m creating 1 extension per page).

I’m working with the latest API, 2025-10, which mandates the use of Polaris web components (This is my first time, and styling/layout has been tough, checking every single property in the documentation).

I’ve successfully created and displayed one page. The problems arose when I decided to create a /components directory outside the extension folders to reuse components across the app’s different extensions, but they are not being loaded.

Simplified structure:

myapp/
├─ app/
├─ extensions/
│  ├─ caui-page-main/
│  │  ├─ src/Main.jsx
│  ├─ caui-page-account/
│  │  ├─ src/Account.jsx
│  └─ extensions-components/
│     ├─ TextTest.jsx  ← Shared component

I’ve tried setting up a package.json to import it like this: import { TextTest } from '@myapp/extensions-components';

Simple component, TextTest.jsx:

JavaScript

import '@shopify/ui-extensions/preact';

export function TextTest() {
  return <s-text>Hi!</s-text>;
}

But it doesn’t work. Do you have any suggestions? I’m not sure how to approach this. Thanks.