mirror of
https://github.com/vector-im/element-call.git
synced 2026-09-10 21:55:19 +00:00
`component/package.json` describes the built component as a package (`@element-hq/element-call-component`: entry, stylesheet subpath, types, peer dependencies) so that a host can depend on `github:element-hq/element-call#<ref>&path:/component`. Its `prepare` script builds on install, since nothing is published yet. For that the component build now lands in `component/dist` instead of the repository's `dist`, and `pnpm build:component` also emits the type declarations (`component/tsconfig.build.json`, `build:component:types`), which previously had to be produced by hand. Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
15 lines
874 B
YAML
15 lines
874 B
YAML
# Makes `component/` a pnpm project of its own rather than a directory inside
|
|
# the repository's workspace. That matters when a host installs the component
|
|
# straight from this repository (`github:element-hq/element-call#…&path:/component`):
|
|
# pnpm prepares such a dependency by running `pnpm install` in this directory,
|
|
# and only a project root gets its `prepare` script (see package.json) run, which
|
|
# is what builds `dist/`. Inside the repository's own workspace the install
|
|
# would silently target the repository instead and build nothing.
|
|
#
|
|
# Consequence for development: pnpm commands run from within this directory see
|
|
# this project, not the repository; run them from the repository root.
|
|
|
|
# Nothing to install here: the peers in package.json are the host's, and the
|
|
# build runs against the repository's own node_modules (see `prepare`).
|
|
autoInstallPeers: false
|