I was wondering if there is any performance issue if I should use a local script to create my UI, or should I just use StarterGui
Why would you even want to use a script to create UI. Not only is it inefficient and tedious, but it would be really hard to navigate to individual UIs.
Just use StarterGui, its much easier to create and navigate, and there is no gain in making it in a script.
Although it is easier to create UI straight in Roblox studio. There are frameworks like fusion and roact to help create UI. I personally create them straight in studio but it really boils down to if you have the time and whether you prefer it. I will add that It can be very tedious to learn and even creating a simple UI will take some time to do.
@sata5pa3da @KdudeDev I use roact, which is more of a reuseable UI, with roact, it allows me to use the same UI, in a different way, I could have customizable options, with just simple booleans and states.
Some things you create UI in code for, like if you have an inventory system, obviously you need to script the creation of the items in the inventory UI.