--[[ ROBLOX TODO: Unhandled node for type: TSIndexedAccessType ]]
--[[ export const serialize: NewPlugin['serialize'] ]]

local function serialize(
	element: any,
	config: Config,
	indentation: string,
	depth: number,
	refs: Refs,
	printer: Printer
): string
	depth += 1
	return if depth > config.maxDepth
		then printElementAsLeaf(getType(element), config)
		else printElement(
			getType(element),
			printProps(getPropKeys(element), element.props, config, indentation .. config.indent, depth, refs, printer),
			printChildren(
				getChildren(element.props.children),
				config,
				indentation .. config.indent,
				depth,
				refs,
				printer
			),
			config,
			indentation
		)
end

exports.serialize = serialize