Przejdź do treści
Biblioteka skilli
Programowanie · Budowanie i kod

typescript-strictness

/typescript-strictness

Pomaga stopniowo włączać i migrować do ścisłych flag TypeScript, aby kompilator wychwytywał realne błędy bez przepisywania całej bazy kodu.

Repozytorium
AI-SKILLS ↗
Licencja
MIT
Ostatnia zmiana repozytorium
05.09.2026

Ocena i bezpieczeństwo

90/ 100Klasa: dobry
Format25 / 25
Frontmatter z nazwą i opisem, poprawna nazwa, opis do 1024 znaków, nazwa zgodna z folderem.
Odkrywalność25 / 25
Opis mówi, kiedy użyć skilla, ma sensowną długość i jest w 3. osobie.
Treść25 / 35
Co najmniej 150 słów i do 500 linii, nagłówki, listy kroków, przykłady albo kod.
Higiena15 / 15
Bez zaślepek typu TODO, bez ścieżek Windows, z licencją.
Ryzykobrak sygnałów w skanie
Pliki w paczce
1
Skrypty
0
Komentarze HTML
0
Adresy URL w SKILL.md
0
Przestarzałość

Brak sygnałów. Repozytorium zmienione 05.09.2026, bez odwołań do wycofanych modeli i API.

Licencja

MIT, otwarta: można używać i zmieniać, z zachowaniem informacji o autorze.

Co robi i kiedy

Pomaga stopniowo włączać i migrować do ścisłych flag TypeScript, aby kompilator wychwytywał realne błędy bez przepisywania całej bazy kodu.

Oryginalny opis (EN)

Turn on and migrate to TypeScript's strict flags incrementally so the compiler catches real bugs. Use when configuring TypeScript strictness or tightening a loose codebase without a big-bang rewrite.

Jak działa

  1. Method
  2. Boundaries
Sekcje z nagłówków SKILL.md, w oryginale · 50 linii, 387 słów
Podgląd SKILL.md
---
name: typescript-strictness
description: Turn on and migrate to TypeScript's strict flags incrementally so the compiler catches real bugs. Use when configuring TypeScript strictness or tightening a loose codebase without a big-bang rewrite.
---

# TypeScript strictness

TypeScript's value is proportional to how strict you let it be. A loose
config with implicit `any` everywhere is JavaScript with extra syntax;
strict mode is where the compiler starts catching the null-deref and
type-mismatch bugs before they ship.

## Method

1. **Turn on `strict` for new projects, full stop.** It enables the
   flags that matter together (`strictNullChecks`, `noImplicitAny`,
   `strictFunctionTypes`, and the rest). Everything below is about
   getting an existing loose codebase there without a rewrite.
2. **Migrate flag by flag, not all at once.** Enabling `strict` on a
   large loose codebase surfaces thousands of errors and stalls. Turn on
   one flag at a time, fix its errors, commit, repeat. `noImplicitAny`
   and `strictNullChecks` are the two that find the most bugs and cause
   the most work; schedule them deliberately.
3. **Add `strictNullChecks` early and take it seriously.** It separates
   `T` from `T | null | undefined`, forcing you to handle absence at
   every boundary. This is the single flag that prevents the most runtime
   errors (the "cannot read property of undefined" class; see
   null-handling). Expect it to touch a lot of code; the errors are real
   bugs, not noise.
4. **Reach for `noUncheckedIndexedAccess` once strict is stable.** It
   makes `arr[i]` return `T | undefined`, catching the off-by-one and
   missing-key access that `strict` alone misses. High value, moderate
   friction; add it after the baseline is clean.
5. **Contain the migration debt visibly.** Where you must defer fixes,
   use explicit `// @ts-expect-error` with a reason (it fails the build
   when the underlying issue is fixed, unlike `@ts-ignore` which rots
   silently), and track the count downward. Never widen types to `any`
   to silence errors; that spreads the looseness (see ts-api-types).
6. **Enforce in CI and forbid backsliding.** `tsc --noEmit` in CI (see
   linting-setup); lint rules against `any` and non-null assertions
   (`!`) except where justified. A strict config that any PR can quietly
   loosen is not strict.

## Boundaries

- Strictness catches type bugs, not logic bugs; a fully-typed program can
  still be wrong (see testing-strategy).
- Third-party libraries with weak or wrong types leak looseness in;
  isolate them behind typed wrappers at the boundary rather than
  weakening your own config (see ts-api-types).
- `strict` is a floor, not the ceiling: `noUncheckedIndexedAccess`,
  `exactOptionalPropertyTypes`, and lint rules add more, each with its
  own friction-to-value tradeoff to weigh per project.

Wersje

W bazie nie ma innych skilli o nazwie typescript-strictness.

Migawka bazy z 13.11.2026 · wersja paczki 120e3b8f60e5 (skrót SHA-256 całej paczki)

Pobrania w ostatnich 30 dniach: 0 · ranking

Zgłoś problem z tym skillem: szkodliwa treść, błędny opis albo prośba autora o usunięcie.

Podobne skille

  • 100typescript-strict
    Pisze i recenzuje TypeScript w trybie strict z flagami noUncheckedIndexedAccess i exactOptionalPropertyTypes oraz migruje luźne bazy kodu do pełnej ścisłości flaga po fladze.
  • 95typescript-advanced-compiler-config
    Pomaga skonfigurować kompilator TypeScript: strukturę tsconfig.json, flagi trybu strict, strategie rozwiązywania modułów oraz diagnozowanie i przyspieszanie wolnego sprawdzania typów.
  • 100typescript-strict
    Pomaga pisać i naprawiać TypeScript tam, gdzie liczy się bezpieczeństwo typów: zawężanie, rzutowania i tsc.
  • 90typescript-best-practices
    Kształtuje kod TypeScript w stronę wąskich typów, unii, wyczerpującej obsługi wariantów i ścisłych flag kompilatora.
  • 100typescript-strict
    Wprowadza konwencje ścisłego TypeScript: tryb strict, zakaz any, typy narzędziowe i obsługę błędów.
  • 90typescript-review
    Pomaga recenzować kod TypeScript i TSX, wskazując, co warto skomentować, a co kompilator i linter już wyłapują, oraz unikać fałszywych alarmów.

Uwagi i zgłoszenia

Wiadomość trafi do Bartosza Sokolińskiego. Adres e-mail jest potrzebny tylko do odpowiedzi. Szczegóły w polityce prywatności.