Use turbo for building and watching concurrently (#5808)

- Add `typecheck` command to all packages.
- Use turbo to build and watch concurrently with caches.
- Remove root `bin/` folder with last global scripts
- `bin/companion.sh` -> `@uppy/companion/start-dev` (`yarn
start:companion` still works)
- `bin/build-components.mjs` -> `@uppy/components/migrate.mjs` (`yarn
migrate:components` can be used to run it). This only needs to be ran
for new components, not changing existing ones, so that's why it's not
part of the build process.

turbo is smart enough to build dependencies within a package first
before building the package itself (e.g if wanting to build @uppy/audio,
build @uppy/utils first). Unfortunately @uppy/core is a peer dep
everywhere turbo does not take it into account, yet it must be build
first to avoid race conditions. Therefor I added a turbo.json to each
package, which you normally never need, but this is an odd case I
suppose. Other solutions ran into cyclic dep errors.

Another PR would move over the test commands to turbo too.
This commit is contained in:
Merlijn Vos 2025-07-10 13:21:18 +02:00 committed by GitHub
parent 455abb32af
commit 271db86ad0
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
101 changed files with 839 additions and 547 deletions

1
.gitignore vendored
View file

@ -17,6 +17,7 @@ yarn-error.log
tsconfig.tsbuildinfo
tsconfig.build.tsbuildinfo
.svelte-kit
.turbo
dist/
lib/