vercel / turborepo

Build system optimized for JavaScript and TypeScript, written in Rust
https://turbo.build/repo/docs
MIT License
26.45k stars 1.84k forks source link

Docs: Crafting Your Repository - couldn't find package "@repo/typescript-config@workspace:*" #8862

Open dorfurman opened 3 months ago

dorfurman commented 3 months ago

What is the improvement or update you wish to see?

I ran through the guide up until I had to add the math dependency -

"dependencies": {
    "@repo/math": "*",
}

And came into an error - error Couldn't find package "@repo/typescript-config@workspace:*" required by "@repo/math@0.0.0" on the "npm" registry.

Searched everywhere and still couldn't figure what's the issue.

Is there any context that might help us understand?

Wrote everything above

Does the docs page already exist? Please link to it.

https://turbo.build/repo/docs/crafting-your-repository/creating-an-internal-package

tknickman commented 3 months ago

Please provide a reproduction repo and we can help you more. This is likely due to a mismatch between the package manager and workspace syntax.

boutchitos commented 1 month ago

I will go with this guess:

I have noticed that: pnpm dlx create-turbo@latest --example basic differ from pnpm dlx create-turbo@latest --example with-vite in regards of config folder name.

with-vite generates under packages/config-typescript, and basic under packages/typescript-config. This is an inconsistency between the two (I did not ran all the examples).

Could it be this? I will open an issue for that specific matter.

boutchitos commented 1 month ago

I have open this issue that could be related: https://github.com/vercel/turborepo/issues/9191

khairuninandrey commented 3 weeks ago

I am using yarn instead of pnpm but I ran into the same issue. I replaced "@repo/typescript-config": "workspace: " in packages/math/package.json with "@repo/typescript-config": "" and it worked for me.