<!-- mobian-agent-page publisher="dailydev" canonical="https://daily.dev/posts/one-thing-nobody-explained-to-you-about-typescript-owwrlk99n" -->

---
title: One Thing Nobody Explained To You About TypeScript
description: Learn about the tsconfig.json file in TypeScript, how it configures the language, and its impact on modules and environments. Discover the importance of using...
canonical: https://daily.dev/posts/one-thing-nobody-explained-to-you-about-typescript-owwrlk99n
twitter:card: summary_large_image
twitter:site: @dailydotdev
og:type: website
og:site_name: daily.dev
og:title: One Thing Nobody Explained To You About TypeScript | daily.dev
og:description: Learn about the tsconfig.json file in TypeScript, how it configures the language, and its impact on modules and environments. Discover the importance of using...
og:url: https://daily.dev/posts/one-thing-nobody-explained-to-you-about-typescript-owwrlk99n
og:image: https://api.daily.dev/og/posts/OWWRLK99n.png
og:image:alt: One Thing Nobody Explained To You About TypeScript
og:image:width: 1200
og:image:height: 630
og:locale: en
---

> ## Documentation Index
> Fetch the complete documentation index at: https://daily.dev/llms.txt
> Use this file to discover all available pages before exploring further.

# One Thing Nobody Explained To You About TypeScript

**[Community Picks](https://daily.dev/sources/community)** · 9 min read · 305 upvotes · 12 comments

## Summary

Learn about the tsconfig.json file in TypeScript, how it configures the language, and its impact on modules and environments. Discover the importance of using multiple tsconfig.json files for different layers and intentions in your project.

## Full article

daily.dev links to this article rather than hosting it. Read it at the original source: <https://redd.one/blog/one-thing-nobody-explained-to-you-about-typescript>

## Community discussion

Top comments from developers on daily.dev.

**@lcrojano** · 3 upvotes

> The article was interesting, is helpful in avoiding this common mistake.

**@codart** · 2 upvotes

> But what if I co-locate my test files with my code file. For example:
> ```
> ...
> foo.test.ts
> foo.ts
> ...
> ```
>
> I found it helpful to group related files together so I can quickly edit and manage them. But by doing so, I can't follow your advice that create separated tsconfig files

**@dinhego** · 1 upvotes

> This was truly clarifying!

**@threefields** · 0 upvotes

> Very helpful to be reminded of seemingly tiny things that you thought you completely knew about, but actually not to their full extend!

**@rishimeena** · 0 upvotes

> True

## Similar posts on daily.dev

- [Don’t just attend KubeCon \+ CloudNativeCon, Merge Forward your experience\!](https://daily.dev/posts/don-t-just-attend-kubecon-cloudnativecon-merge-forward-your-experience--l0rpp73x8) · CNCF · 1 upvotes · 0 comments
- [Announcing H2 2026 KCDs](https://daily.dev/posts/announcing-h2-2026-kcds-m96goajm1) · CNCF · 1 upvotes · 0 comments
- [Two months of Open Community Groups](https://daily.dev/posts/two-months-of-open-community-groups-asf52zhbs) · CNCF · 0 upvotes · 0 comments

---

Tags: [#javascript](https://daily.dev/tags/javascript), [#testing](https://daily.dev/tags/testing), [#typescript](https://daily.dev/tags/typescript), [#vite](https://daily.dev/tags/vite), [#vitest](https://daily.dev/tags/vitest)

[View this post on daily.dev](https://daily.dev/posts/one-thing-nobody-explained-to-you-about-typescript-owwrlk99n)

```json
{"@context":"https://schema.org","@graph":[{"@type":"Organization","@id":"https://daily.dev/#organization","name":"daily.dev","url":"https://daily.dev","logo":{"@type":"ImageObject","url":"https://daily.dev/apple-touch-icon.png","width":180,"height":180},"sameAs":["https://twitter.com/dailydotdev","https://github.com/dailydotdev","https://www.linkedin.com/company/daily-dev-ltd"]},{"@type":"WebSite","@id":"https://daily.dev/#website","url":"https://daily.dev","name":"daily.dev","publisher":{"@id":"https://daily.dev/#organization"},"potentialAction":{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https://daily.dev/search?q={search_term_string}"},"query-input":"required name=search_term_string"}}]}
{"@context":"https://schema.org","@type":"TechArticle","headline":"One Thing Nobody Explained To You About TypeScript","url":"https://daily.dev/posts/one-thing-nobody-explained-to-you-about-typescript-owwrlk99n","mainEntityOfPage":{"@type":"WebPage","@id":"https://daily.dev/posts/one-thing-nobody-explained-to-you-about-typescript-owwrlk99n"},"datePublished":"2023-09-28T18:17:52.518Z","dateModified":"2024-07-02T02:13:08.265Z","description":"Learn about the tsconfig.json file in TypeScript, how it configures the language, and its impact on modules and environments. Discover the importance of using...","image":"https://media.daily.dev/image/upload/f_auto,q_auto/v1/posts/88f7e48856beb22ba58bd8223c2e2c32?_a=AQAEufR","thumbnailUrl":"https://media.daily.dev/image/upload/f_auto,q_auto/v1/posts/88f7e48856beb22ba58bd8223c2e2c32?_a=AQAEufR","isAccessibleForFree":true,"articleSection":"Community Picks","inLanguage":"en","publisher":{"@type":"Organization","name":"daily.dev","url":"https://daily.dev","logo":{"@type":"ImageObject","url":"https://daily.dev/apple-touch-icon.png","width":180,"height":180}},"author":{"@type":"Organization","name":"Community Picks","logo":"https://media.daily.dev/image/upload/t_logo,f_auto/v1655817725/logos/community","url":"https://daily.dev/sources/community"},"commentCount":12,"discussionUrl":"https://daily.dev/posts/one-thing-nobody-explained-to-you-about-typescript-owwrlk99n","interactionStatistic":[{"@type":"InteractionCounter","interactionType":{"@type":"LikeAction"},"userInteractionCount":305},{"@type":"InteractionCounter","interactionType":{"@type":"CommentAction"},"userInteractionCount":12}],"keywords":"javascript,testing,typescript,vite,vitest","timeRequired":"PT9M"}
{"@context":"https://schema.org","@type":"BreadcrumbList","itemListElement":[{"@type":"ListItem","position":1,"name":"Home","item":"https://daily.dev"},{"@type":"ListItem","position":2,"name":"Community Picks","item":"https://daily.dev/sources/community"},{"@type":"ListItem","position":3,"name":"One Thing Nobody Explained To You About TypeScript"}]}
{"@context":"https://schema.org","@type":"WebPage","@id":"https://daily.dev/posts/one-thing-nobody-explained-to-you-about-typescript-owwrlk99n","comment":[{"@type":"Comment","text":"The article was interesting, is helpful in avoiding this common mistake.","datePublished":"2023-09-29T15:53:48.547Z","url":"https://daily.dev/posts/OWWRLK99n#c-8Jm4mUSP9","author":{"@type":"Person","name":"luis carlos rojano","url":"https://daily.dev/lcrojano","image":"https://media.daily.dev/image/upload/s--5AUFOyfC--/f_auto,q_auto/v1/avatars/avatar_M6CnhzFVJiNHFeaQjV882"},"interactionStatistic":{"@type":"InteractionCounter","interactionType":{"@type":"LikeAction"},"userInteractionCount":3}},{"@type":"Comment","text":"But what if I co-locate my test files with my code file. For example:\n...\nfoo.test.ts\nfoo.ts\n...\n\nI found it helpful to group related files together so I can quickly edit and manage them. But by doing so, I can’t follow your advice that create separated tsconfig files","datePublished":"2023-09-30T09:42:56.479Z","dateModified":"2023-09-30T09:43:26.906Z","url":"https://daily.dev/posts/OWWRLK99n#c-zdzSsSAAZ","author":{"@type":"Person","name":"Mạnh Đê Tê","url":"https://daily.dev/codart","image":"https://lh3.googleusercontent.com/a/ALm5wu3yyLytiQHRr4_rMINkrt5kUKBXdWEFnedaoXyfzw=s96-c"},"interactionStatistic":{"@type":"InteractionCounter","interactionType":{"@type":"LikeAction"},"userInteractionCount":2}},{"@type":"Comment","text":"This was truly clarifying!","datePublished":"2023-09-29T12:06:11.789Z","url":"https://daily.dev/posts/OWWRLK99n#c-7uI5xHZxl","author":{"@type":"Person","name":"Diego Rapoport","url":"https://daily.dev/dinhego","image":"https://avatars.githubusercontent.com/u/66575787?v=4"},"interactionStatistic":{"@type":"InteractionCounter","interactionType":{"@type":"LikeAction"},"userInteractionCount":1}},{"@type":"Comment","text":"Very helpful to be reminded of seemingly tiny things that you thought you completely knew about, but actually not to their full extend!","datePublished":"2023-09-30T14:01:20.376Z","url":"https://daily.dev/posts/OWWRLK99n#c-h9DM8metf","author":{"@type":"Person","name":"Stefanos Trialonis","url":"https://daily.dev/threefields","image":"https://avatars.githubusercontent.com/u/5868446?v=4"}},{"@type":"Comment","text":"True","datePublished":"2023-10-04T12:33:42.881Z","url":"https://daily.dev/posts/OWWRLK99n#c-2dBhwZh6v","author":{"@type":"Person","name":"Rishi Meena","url":"https://daily.dev/rishimeena","image":"https://lh3.googleusercontent.com/a/ACg8ocJDymuJTCilAjXkk0o_rLctIkwVmm-RdG7L2J55UC1UzUU=s96-c"}}]}
```

