ISSUE DESCRIPTION False positive unused file for Vercel vercel.ts config What happened?…
- User
ISSUE DESCRIPTION
False positive unused file for Vercel vercel.ts config
What happened?
fallow dead-codereportsapps/web/vercel.tsas an unused file, but Vercel treatsvercel.tsas a project configuration file that is discovered and executed by convention.The file is not imported by application source, so it looks unused to a pure import graph. It should be treated as a Vercel config entrypoint.
Vercel docs say:
vercel.tsconfigures and overrides Vercel project behavior.- Unlike
vercel.json,vercel.tsexecutes at build time. - The final config must be exported as
config. - Vercel also supports
vercel.js,vercel.mjs,vercel.cjs, andvercel.mts.
The
@vercel/configpackage also treatsvercel.tsas the config input:packages/config/README.mdsays to create avercel.tsfile in the project root.packages/config/README.mdsaysvercel.tsis automatically compiled duringvercel build,vercel dev, andvercel deploy.packages/config/src/cli.tsresolvesprocess.cwd()/vercel.ts.packages/config/src/cli.tsimports the config module and collects named exports.
- Assistant
I’ll inspect the repository for the Vercel plugin and its configuration/always-used patterns, then identify the relevant tests and implementation conventions. I’ll reproduce the behavior if practical, make the smallest targeted change, run affected tests, and review the diff before submitting.
- Assistant
The repository has no Vercel plugin at present, so merely extending an existing framework pattern would not satisfy “when Vercel is active” for projects that only use Vercel tooling. I’ll add a small built-in Vercel plugin activated by
vercelor@vercel/config, with the five documented programmatic config extensions as both config and always-used patterns. This also lets the normal config parser credit imports fromvercel.ts. - Assistant
The first compile exposed that plugin modules rely on lexical access to the parent’s
PluginandPluginResult; I corrected the imports to match repository conventions. The affected registry test suite now passes (149 tests), confirming registration, activation, static pattern aggregation, and existing plugin behavior remain intact. I’ll now run the broader core library tests and inspect the final diff. - Assistant
The full
fallow-corelibrary suite passes (2,461 tests), formatting andgit diff --checkare clean. The final implementation is limited to registering the new built-in plugin and its source file; it recognizes all requested extensions, activates from either Vercel package, protects the files from unused-file reporting, and parses imports from them. I’m submitting these changes now.
Other models, same or similar prompt
Responses were produced in different, uncontrolled contexts (system prompts, settings, prior turns). This is not a benchmark.