# TypeScript 7 ships no JavaScript compiler API. Storybook's docgen
# (react-docgen-typescript) loads it through an optional `typescript` peer, which
# pnpm resolves from the parent's dependencies: giving @storybook/react-vite, the
# subtree's root, TypeScript 6's compat package makes every typescript peer under
# it resolve there. Remove it once TypeScript 7.1 ships an API the docgen tools
# can load. It stays above allowBuilds, which the scaffolder rewrites.
packageExtensions:
  "@storybook/react-vite":
    dependencies:
      typescript: "npm:@typescript/typescript6@6.0.2"

# pnpm 11 blocks dependency build scripts by default, and its pre-run deps
# check then aborts every pnpm command (install/build/exec) with
# ERR_PNPM_IGNORED_BUILDS. Pre-approve the builds this app actually needs so a
# fresh scaffold works out of the box. (In pnpm 11 `allowBuilds` replaced
# `onlyBuiltDependencies`; values are booleans, not a list.)
allowBuilds:
  esbuild: true
  msw: true
  sharp: true
