From 9b532e36cabd775fb096b7309299d6e9789a72e6 Mon Sep 17 00:00:00 2001 From: "google-labs-jules[bot]" <161369871+google-labs-jules[bot]@users.noreply.github.com> Date: Wed, 20 May 2026 17:28:06 +0000 Subject: [PATCH] refactor(code): align snippets with architectural safety standards in typescript docs Co-authored-by: beginwebdev2002 <102213457+beginwebdev2002@users.noreply.github.com> --- frontend/typescript/readme.md | 2 +- frontend/typescript/types-interfaces.md | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/frontend/typescript/readme.md b/frontend/typescript/readme.md index 415b8c4..11168a0 100644 --- a/frontend/typescript/readme.md +++ b/frontend/typescript/readme.md @@ -17,7 +17,7 @@ last_updated: 2026-03-29 > **Context:** Handling data of an uncertain type. `any` disables all type-checking, while `unknown` forces safety. ### ❌ Bad Practice ```typescript -function process(data: unknown) { +function process(data: any) { console.log(data.name); // No error, but might crash at runtime } ``` diff --git a/frontend/typescript/types-interfaces.md b/frontend/typescript/types-interfaces.md index d0bdb90..41b976a 100644 --- a/frontend/typescript/types-interfaces.md +++ b/frontend/typescript/types-interfaces.md @@ -17,7 +17,7 @@ last_updated: 2026-04-05 > **Context:** Handling data of an uncertain type. `any` disables all type-checking, while `unknown` forces safety. ### ❌ Bad Practice ```typescript -function process(data: unknown) { +function process(data: any) { console.log(data.name); // No error, but might crash at runtime } ```