Admin-x-design-system build Showing -- module "src/Boilerplate.tsx" cannot be external

Hey Tea,
I’m facing some build error as below, could you please help on it ?

  • What’s your URL? This is the easiest way for others to debug your issue
    Everytime I build admin-x-design-system
  • What version of Ghost are you using?
    The latest code in main branch
  • What configuration?
  • What browser?
  • What errors or information do you see in the console?
- PS F:\nodejs\Ghost\apps\admin-x-design-system> npm run build
npm info using npm@10.7.0
npm info using node@v18.20.4
npm info found workspace root at F:\nodejs\Ghost

> @tryghost/admin-x-design-system@0.0.0 build
> tsc -p tsconfig.declaration.json && vite build

Entry module "src/Boilerplate.tsx" cannot be external.
error during build:
RollupError: Entry module "src/Boilerplate.tsx" cannot be external.
    at error (file:///F:/nodejs/Ghost/node_modules/rollup/dist/es/shared/node-entry.js:2245:30)
    at ModuleLoader.loadEntryModule (file:///F:/nodejs/Ghost/node_modules/rollup/dist/es/shared/node-entry.js:24763:20)
    at async Promise.all (index 0)
  • What steps could someone else take to reproduce the issue you’re having?

Are you intending to edit the core? If not, the easiest way to get a working install is to use the ghost cli! :)

Thanks for the reply Cathy!
I want to go through the code of core and learn. So I’m trying to build the source code in my local.