string_trunc_right: simple string truncation

View source: R/utils.R

string_trunc_rightR Documentation

simple string truncation

Description

replacement for stringr::trunc() so we don't need a package dependency for just 1 function (our code was adapter therefrom)

Usage

string_trunc_right(string, width, trim_left = FALSE)

Arguments

string

string that should be truncated

width

desired max length

trim_left

instead of right trunc (default), do left instead

Value

truncated variant of input string


goat documentation built on April 3, 2025, 6:05 p.m.