Skip to main content

typescript

TypeScript coding standards and conventions including file naming rules

ソース情報

リポジトリ
forcedotcom/apex-language-support
ソースの最終更新活動
2026年6月23日 22:16
検出された SKILL.md の言語
英語
スター
11
フォーク
3

インストール方法

デフォルトでは、最初にソースを確認する Prompt が選択されています。直接コマンドに切り替えるか、ローカルコピーをダウンロードすることもできます。

ソースファイルを確認

インストールを決める前に、SKILL.md と SkillsMP に表示されている付属ファイルをお読みください。

ファイルエクスプローラー
2 ファイル

SKILL.md を表示中

SKILL.md
ソースの指示 · 読み取り専用プレビュー
name
typescript
description
TypeScript coding standards and conventions including file naming rules
- new file copyright header: use year **2026** (e.g. `Copyright (c) 2026, salesforce.com, inc.`) - no barrel files - avoid type assertions (`as Foo` or `as unknown as` or `Foo!`). do guards or Effect.schema stuff (ex `is`) instead - no `void` for async - use async/effect (exception [vscode-window-messages](../vscode-window-messages/SKILL.md)) - no `export *` - name exports explicitly - prefer `undefined` over null (unless server requires null) - prefer `undefined` over empty string - prefer map/filter over loops/conditionals - avoid mutation - avoid `any` - no enums or namespaces (enums compile to weird JS; use string union types instead; exception: interfaces defined outside this repo that we can't change) - no runtime errors for developer mistakes (use types to ensure exhaustive switch/case; don't throw for null/undefined when input/consumer is within our control) - avoid fallbacks unless absolutely necessary — a fallback path is usually a bandaid on a bug that should be fixed upstream. Fix the root cause; don't paper over it with a default/alternate path that hides the real failure. If a fallback is genuinely required, comment why the upstream fix isn't possible. - .ts filenames: camelCase, no hyphens, no leading capitals - preserve comments when refactoring; remove if wrong/obsolete - exported functions: single-line jsdoc /\*_ foo _/ if name unclear; no params/return (TS provides types) - look for uses of (Object|Map).groupBy instead of older patterns LSP position indexing and VS Code web extension constraints: [references/lsp-and-web-extension.md](references/lsp-and-web-extension.md)
GitHubで見る