Skip to content

Instantly share code, notes, and snippets.

View EstebenR's full-sized avatar
😁

Esteban EstebenR

😁
View GitHub Profile
@EstebenR
EstebenR / OrderedInsert.luau
Created December 12, 2025 15:41
Ordered insert using binary search for tables, use in Roblox or Luau in general
return function<V>(list: { V }, item: V, lessThan: ((V, V) -> boolean)?): ()
--Binary search for ideal spot
local compare: (any, any) -> boolean = lessThan or function(a, b)
return a < b
end
local left = 1
local right = #list
local insertPos = #list + 1
@EstebenR
EstebenR / fusion snippets.code-snippets
Created December 10, 2025 15:55
Snippets I commonly use for Fusion development in roblox
{
// Each snippet is defined under a snippet name and has a scope, prefix, body and
// description. Add comma separated ids of the languages where the snippet is applicable in the scope field. If scope
// is left empty or omitted, the snippet gets applied to all languages. The prefix is what is
// used to trigger the snippet and the body will be expanded and inserted. Possible variables are:
// $1, $2 for tab stops, $0 for the final cursor position, and ${1:label}, ${2:another} for placeholders.
// Placeholders with the same ids are connected.
// Example:
// "Print to console": {
// "scope": "javascript,typescript",