Skip to content
aiWikis.org

TypeScript And JavaScript Coding Standard

Use TypeScript when the project build supports it. Use plain JavaScript only when it matches the local site or tool.

Metadata

FieldValue
Source siteaiwikis.org
Source URLhttps://aiwikis.org/
Canonical AIWikis URLhttps://aiwikis.org/files/aiwikis/wiki-global-coding-standards-typescript-javascript-md-c8e35f3e/
Source referencewiki/global/coding-standards/typescript-javascript.md
File typemd
Content categoryllm-wiki
Last fetched2026-05-08T21:22:18.3035107Z
Last changed2026-05-08T02:36:59.1954645Z
Content hashsha256:c8e35f3eb8e06334654dd5a91f979f03c99e68f2f302a679c5bd899a09f1decb
Import statusunchanged
Raw source layerdata/sources/aiwikis/wiki-global-coding-standards-typescript-javascript-md-c8e35f3eb8e0.md
Normalized source layerdata/normalized/aiwikis/wiki-global-coding-standards-typescript-javascript-md-c8e35f3eb8e0.txt

Current File Content

Structure Preview

  • TypeScript And JavaScript Coding Standard
  • Code Shape
  • UI Behavior
  • Verification

Raw Version

---
uai_id: "7c9765b4-cf0e-449e-8478-3aa14ccca299"
type: "coding-standard"
owner: "AIWikis maintainers"
status: "reviewed"
source_system: "AIWikis.org global"
source_status: "local synthesis from browser and tooling implementation practice"
sensitivity: "public-safe source-side memory"
agent_use: "load for TypeScript, JavaScript, browser UI, and Node utility work"
lineage:
  - "wiki/global/coding-standards/index.md"
source_trace:
  - "wiki/global/coding-standards/typescript-javascript.md"
confidence: 0.8
confidence_label: "reviewed-local"
last_linted: "2026-05-08T00:00:00Z"
handoff_export: "include"
aliases:
  - "TypeScript Coding Standard"
  - "JavaScript Coding Standard"
---

# TypeScript And JavaScript Coding Standard

Use TypeScript when the project build supports it. Use plain JavaScript only when it matches the local site or tool.

## Code Shape

- Keep browser code framework-light unless the project already uses a framework.
- Prefer small modules with explicit inputs over global mutable state.
- Validate external data at boundaries.
- Keep DOM selectors stable and local to the component or page they serve.
- Avoid hidden network calls in content pages unless the feature clearly requires them.

## UI Behavior

- Build controls that match the task: buttons for commands, toggles for binary state, tabs for views, and inputs for data entry.
- Do not use visible explanatory copy as a substitute for a usable interface.
- Keep progressive enhancement in mind for WordPress and static content pages.

## Verification

- Run lint/build/test commands when the project provides them.
- Use browser smoke checks for route, interaction, and layout changes.
- Check console errors when changing client-side behavior.

Why This File Exists

This is a LLM Wiki memory file from aiwikis.org. It is shown here because AIWikis.org is demonstrating the real source files that make the UAIX / LLM Wiki memory system work, not only summarizing those systems after the fact.

Role

This file belongs to the source-side wiki layer. It preserves a focused concept, source proxy, graph record, or operating rule so the public site can cite reviewed conclusions without flattening every reason into a single long page.

Structure

The file is structured around these visible headings: TypeScript And JavaScript Coding Standard; Code Shape; UI Behavior; Verification. Those headings are retrieval anchors: a crawler or LLM can decide whether the file is relevant before reading every line.

Prompt-Size And Retrieval Benefit

Keeping this material in a separate file reduces prompt pressure because an agent can load this exact unit only when its role, source site, category, or hash is relevant. The surrounding index pages point to it, while this page preserves the full content for audit and exact recall.

How To Use It

  • Humans should read the metadata first, then inspect the raw content when they need exact wording or provenance.
  • LLMs and agents should use the source site, category, hash, headings, and related files to decide whether this file belongs in the active prompt.
  • Crawlers should treat the AIWikis page as transparent evidence and follow the source URL/source reference for authority boundaries.
  • Future maintainers should regenerate this page whenever the source hash changes, then review the explanation if the role or structure changed.

Update Requirements

When this source file changes, update the raw source layer, normalized source layer, hash history, this rendered page, generated explanation, source-file inventory, changed-files report, and any source-section index that links to it.

Related Pages

Provenance And History

  • Current observation: 2026-05-08T21:22:18.3035107Z
  • Source origin: current-source-workspace
  • Retrieval method: local-source-workspace
  • Duplicate group: sfg-595 (primary)
  • Historical hash records are stored in data/hashes/source-file-history.jsonl.

Machine-Readable Metadata

{
    "title":  "TypeScript And JavaScript Coding Standard",
    "source_site":  "aiwikis.org",
    "source_url":  "https://aiwikis.org/",
    "canonical_url":  "https://aiwikis.org/files/aiwikis/wiki-global-coding-standards-typescript-javascript-md-c8e35f3e/",
    "source_reference":  "wiki/global/coding-standards/typescript-javascript.md",
    "file_type":  "md",
    "content_category":  "llm-wiki",
    "content_hash":  "sha256:c8e35f3eb8e06334654dd5a91f979f03c99e68f2f302a679c5bd899a09f1decb",
    "last_fetched":  "2026-05-08T21:22:18.3035107Z",
    "last_changed":  "2026-05-08T02:36:59.1954645Z",
    "import_status":  "unchanged",
    "duplicate_group_id":  "sfg-595",
    "duplicate_role":  "primary",
    "related_files":  [

                      ],
    "generated_explanation":  true,
    "explanation_last_generated":  "2026-05-08T21:22:18.3035107Z"
}