- Test:
deno task test(all tests),deno task test:parallel(all tests in parallel),deno task test:coverage(all tests with coverage) - Single test:
deno test -A tests/path/to/specific.test.mjs - Lint:
deno task lint(check),deno task lint:fix(autofix) - Format:
deno task format(autoformat),deno task format:check(check only) - Bundle:
deno task bundle - Coverage:
deno task coverage:report(with coverage report)
- Runtime: Deno with TypeScript, no Node.js dependencies
- Imports: Use
.tsextensions, relative paths fromsrc/, group imports (types, utils, modules) - Formatting: 2-space indentation, single quotes, no semicolons (Deno fmt)
- Naming: camelCase (variables/functions), PascalCase (classes/types/enums/interfaces)
- Types: Explicit types over
any, use type guards, avoid non-null assertions (!) - Async: Prefer async/await, handle rejections with try/catch
- Error handling: Typed errors with structured properties
- Worker patterns: MessageChannel/MessagePort for worker communication, postMessage/onmessage for worker messaging, store Promise resolvers in Maps
- Testing: Use
@std/expectand@std/testing/bdd,.mjsextension for test files
Follow .github/copilot-instructions.md: DRY principle, single source of truth,
design patterns (factory/strategy), algorithmic solutions, minimal time/space
complexity, English-only code/docs, tests-first mindset.