Automatically detect package aliases
Nobody has claimed this yet.
- Dominant language
- TypeScript
- Stars
- 11.2k
- Forks
- 899
- Avg merge
- 2d 24m
- Merged PRs (30d)
- 40
Description
Context of the issue: https://github.com/unjs/nitro/pull/1553
When tracing external packages, pnpm uses symlinks to the aliases package name from expected name that makes tracing aliases virtually impossible.
Currently, it is possible to specify aliases directly in config:
import { defineNitroConfig } from "nitropack/config";
export default defineNitroConfig({
externals: {
traceAlias: {
"@sxzz/popperjs-es": "@popperjs/core",
},
},
});
Since we have access to the project package.json and tracked dependencies, we might make it automated (to an extend). One possible limitation is when more than one possible alias target is discovered.
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by reading the linked pull request and the externals.traceAlias configuration shown in the issue, then inspect how the project package.json and tracked dependencies are used for external-package tracing. Define how an alias is detected and how multiple possible targets are handled; done means supported aliases are detected automatically without requiring equivalent manual configuration.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- typescript
- Domain
- tooling
- Issue type
- Feature
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 45/100