You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
This is not a problem but a question about best practices.
Using server-less functions in a frontend repo often means sharing the TypeScript configurations, since both the frontend framework and Vercel seem to rely on the tsconfig.json file at the root of the repository for configuring TypeScript.
This is far from ideal, so my question naturally is, how to ask Vercel to use a different source of configuration (for example, tsconfig.vercel.json).
I noticed that inside of the .vercel/cache/node/api folder, multiple folders named after the different functions are found. Inside of these folders, a file name tsconfig-with-tsconfig-json.json contains what seems to be the TypeScript configuration for that specific server-less function:
Now, I can un-ignore this file by adding an exception in .gitignore and commit it to the repository, but that does not feel very sanitary to me, especially that one of the folders in the hierarchy is named cache which indicates that this is a mirror of the information to be found elsewhere.
Can you give advice and/or comment on this. What are your thoughts.
reacted with thumbs up emoji reacted with thumbs down emoji reacted with laugh emoji reacted with hooray emoji reacted with confused emoji reacted with heart emoji reacted with rocket emoji reacted with eyes emoji
-
Problem Description
This is not a problem but a question about best practices.
Using server-less functions in a frontend repo often means sharing the TypeScript configurations, since both the frontend framework and Vercel seem to rely on the
tsconfig.json
file at the root of the repository for configuring TypeScript.This is far from ideal, so my question naturally is, how to ask Vercel to use a different source of configuration (for example,
tsconfig.vercel.json
).I noticed that inside of the
.vercel/cache/node/api
folder, multiple folders named after the different functions are found. Inside of these folders, a file nametsconfig-with-tsconfig-json.json
contains what seems to be the TypeScript configuration for that specific server-less function:Now, I can un-ignore this file by adding an exception in
.gitignore
and commit it to the repository, but that does not feel very sanitary to me, especially that one of the folders in the hierarchy is namedcache
which indicates that this is a mirror of the information to be found elsewhere.Can you give advice and/or comment on this. What are your thoughts.
Beta Was this translation helpful? Give feedback.
All reactions