roblox-ts

R

roblox-ts

Join the community to ask questions about roblox-ts and get answers from other members.

Join

Compiler error with reflection transformer

So, after add the rbxts-transformer-reflection transformer in the plugins json i got this error (im pretty new on this so i dont know why i get this error and srry for my bad english)
No description

Test Post

please ignore
Solution:
this is the solution

React and Vide

I have both react and vide in my project because I am using jabby and react for my own UI. It is forwarding the global to vide which is really weird and how would I change it so it only points to react globals
No description

tables cannot be cyclic

Hello, I got this error and I am not really sure about how to fix it ```ts private pickItem(item: Instance | undefined) { print("ppick up hell yea");...

Serializer<T>.serialize() yielding

everything after "serializing..." is not printing, indicating that serialize() is yielding. i have fiddled around with the schema types to no avail.
No description

Asphalt can't upload asset

``` [WARN asphalt::sync::perform] Failed to sync asset assets/UI/SlotPart.svg: Failed to upload asset Caused by: Failed to get image ID Caused by: Failed to parse asset delivery response Caused by: error decoding response body...

[SOLVED] Confused about OOP

I have method like this which works weirdly ```ts addItem(Item: new (...args: never[]) => Item) { if (this.item === undefined) { this.item = new Item();...

Mocking `loadstring` doesn't work with ui labs with the global mock loadstring

```ts //test.story.ts import fixLoadModule from "common/shared/utils/fix-load-module"; import { runTests } from "common/shared/utils/run-tests"; import { FunctionStory } from "@rbxts/ui-labs";...
No description

New to charm, how would i go about turning this into a state manager?

```ts import { atom } from "@rbxts/charm"; import { Players } from "@rbxts/services"; // Define interfaces for the state...

UI with roblox-ts

Hello! I am new to roblox-ts and I heard about roact for the UI but I see that some tickets have the tag React, and so I am a bit confused on the subject. So I wanted to know what are the good ways or tech to use to make UI with roblox-ts. Thanks in advance!

Using Lastest Jest

The latest vendor uses loadstring, how do you approach writing tests and execute them. I tried littensy's rbxts-jest-test repo and that will give me permission error since loadstring is plugin security. If I was to do this in a storybook with react, it would give me this weird blob of string and a "multiple runtime error". I saw littensy referring to this issue and resetting scripts at runtime. But this doesn't really help in terms of running the code without clicking run
No description

What is considered more optimized?

Changing the visible value or making the element optional ex: {display && <imagebutton/>} or <imagebutton Visible={display} />...

I keep getting this error when trying to publish packages

npm notice Publishing to https://registry.npmjs.org/ with tag latest and public access npm ERR! code E404 npm ERR! 404 Not Found - PUT https://registry.npmjs.org/@rbxts%2fnext-roblox - Not found npm ERR! 404 npm ERR! 404 '@rbxts/[email protected]' is not in this registry....

Color wheel in React

Does it make sense to make the handle draggable? If so, how? Oh, and the main question, how to determine the color the handle is on.
No description

How to fix and optimize React UI

I noticed that my react ui is not optimized at all, the game freezes for a second when opening something. I am new to React, so I understand that most likely I wrote something terrible. I am interested in a guide or advice on how to find the cause of delays, optimize it, fix it, etc.

Attempt to call a table value

```ts import { Manim } from "@rbxts/manim"; import { BaseScene } from "../../scene"; @Manim.Decorators.Scene({...