Class Class — tailwindcss Architecture
Architecture documentation for the Class class in boundary.rs from the tailwindcss codebase.
Entity Profile
Relationship Graph
Source Code
crates/oxide/src/extractor/boundary.rs lines 38–128
enum Class {
// Whitespace, e.g.:
//
// ```
// <div class="flex flex-col items-center"></div>
// ^ ^
// ```
#[bytes(b'\t', b'\n', b'\x0C', b'\r', b' ')]
// Quotes, e.g.:
//
// ```
// <div class="flex">
// ^ ^
// ```
#[bytes(b'"', b'\'', b'`')]
// End of the input, e.g.:
//
// ```
// flex
// ^
// ```
#[bytes(b'\0')]
Common,
// Angular like attributes, e.g.:
//
// ````
// [class.foo]
// ^
// ```
#[bytes(b'.')]
// Twig-like templating languages, e.g.:
//
// ```
// <div class="{% if true %}flex{% else %}block{% endif %}">
// ^
// ```
#[bytes(b'}')]
// XML-like languages where classes are inside the tag, e.g.:
// ```
// <f:case value="0">from-blue-900 to-cyan-200</f:case>
// ^
// ```
#[bytes(b'>')]
Before,
// Clojure and Angular like languages, e.g.:
// ```
// [:div.p-2]
// ^
// [class.foo]
// ^
// ```
#[bytes(b']')]
// Twig like templating languages, e.g.:
//
// ```
// <div class="{% if true %}flex{% else %}block{% endif %}">
// ^
// ```
#[bytes(b'{')]
// Svelte like attributes, e.g.:
//
// ```
// <div class:flex="bool"></div>
// ^
// ```
#[bytes(b'=')]
// Escaped character when embedding one language in another via strings, e.g.:
//
// ```
// $attributes->merge([
// 'x-init' => '$el.classList.add(\'-translate-x-full\'); $el.classList.add(\'transition-transform\')',
// ^ ^
// ]);
// ```
//
// In this case there is some JavaScript embedded in an string in PHP and some of the quotes
// need to be escaped.
#[bytes(b'\\')]
// XML-like languages where classes are inside the tag, e.g.:
// ```
// <f:case value="0">from-blue-900 to-cyan-200</f:case>
// ^
// ```
#[bytes(b'<')]
After,
#[fallback]
Other,
}
Domain
Source
Analyze Your Own Codebase
Get architecture documentation, dependency graphs, and domain analysis for your codebase in minutes.
Try Supermodel Free