Skip to content

Latest commit

 

History

History
33 lines (22 loc) · 689 Bytes

File metadata and controls

33 lines (22 loc) · 689 Bytes
description Common utility helpers.

utils

Common utility helpers.

Import

local utils = require("mods.utils")

Quick Reference

Function Description
quote(v) Smart-quotes a string for readable Lua-like output.

Functions

quote(v) {#fn-quotev}

Smart-quotes a string for readable Lua-like output.

print(utils.quote('He said "hi"'))
-- 'He said "hi"'

print(utils.quote([[say "hi" and 'bye']]))
-- "say \"hi\" and 'bye'"