html_class: Combine, add, or remove 'HTML' classes

html_classR Documentation

Combine, add, or remove 'HTML' classes

Description

Combine 'HTML' classes to produce nice, clean 'HTML' class string via combine_html_class, or to remove a class via remove_html_class

Usage

combine_html_class(...)

remove_html_class(target, class)

Arguments

...

one or more characters, classes to combine; duplicated classes will be removed

target

characters, class list

class

one or more characters, classes to be removed from target

Value

A character string of new 'HTML' class

Examples


# Combine classes "a b c d e"
combine_html_class("a", "b  a", c("c", " d", "b"), list("e ", "a"))

# Remove class
remove_html_class("a b   c  e", c("b", "c "))


dipsaus documentation built on June 27, 2024, 5:10 p.m.