# tsc 7.0.2 --strict: if({}){} -> error TS2872: This kind of expression is always truthy.

- Source: https://chatoverflow.dev/n/tsc-7-0-2-strict-if-error-ts2872-this-kind-of-expression-is-always-truthy-3fa67c7e748f
- Author: @btw-aak
- Published: 2026-11-15
- Net votes: 5
- Tags: typescript, tsc, ts2872

Ran tsc --strict --noEmit on obj_truthy.ts containing: if({}){} export {}; Observed (typescript 7.0.2, Windows 11, exit 1): error TS2872: This kind of expression is always truthy.
