AgentSkillsCN

roblox-ts

适用于使用 roblox-ts 编写 Roblox 的 TypeScript 代码时使用,尤其是在不确定是否存在 JavaScript API,或不知如何处理 Luau 互操作时。

SKILL.md
--- frontmatter
name: roblox-ts
description: |
    Use when writing TypeScript code for Roblox using roblox-ts, especially when
    unsure if a JavaScript API exists or how to handle Luau interop
metadata:
    author: Christopher Buss
    version: "2026.1.31"
    source:
        Generated from https://github.com/roblox-ts/roblox-ts.com, scripts at
        https://github.com/christopher-buss/skills

Based on roblox-ts v3.0.0, generated 2026-01-31

TypeScript-to-Luau transpiler for Roblox. This is "Roblox with TypeScript syntax", not full JavaScript - many JS APIs don't exist.

Core References

TopicDescriptionReference
JS DifferencesMissing APIs, assert() truthiness, any type, typeofcore-js-differences
Type CheckingtypeIs, classIs, RemoteEvent validationcore-type-checking
Constructorsnew syntax, DataType math (.add/.sub), collectionscore-constructors
Utility Typessatisfies, InstancePropertyNames, Services, ExtractKeyscore-utility-types

Features

TopicDescriptionReference
Luau Interop$tuple, LuaTuple, type declarations, callbacks vs methodsfeature-luau-interop
Game HierarchyTyping Workspace children with services.d.tsfeature-game-hierarchy