Struct tailwind_css::TailwindBuilder
source · [−]pub struct TailwindBuilder {
pub obfuscate: bool,
pub objects: BTreeSet<Box<dyn TailwindInstance>>,
pub preflight: PreflightSystem,
pub screens: BreakPointSystem,
pub colors: PaletteSystem,
pub fonts: FontSystem,
}
Fields
obfuscate: bool
objects: BTreeSet<Box<dyn TailwindInstance>>
preflight: PreflightSystem
screens: BreakPointSystem
colors: PaletteSystem
fonts: FontSystem
Implementations
sourceimpl TailwindBuilder
impl TailwindBuilder
sourcepub fn preflight(&mut self) -> &mut PreflightSystem
pub fn preflight(&mut self) -> &mut PreflightSystem
Config for preflight progress
sourcepub fn preflight_addition(&mut self, custom: impl Into<String>)
pub fn preflight_addition(&mut self, custom: impl Into<String>)
Add custom preflight information
sourceimpl TailwindBuilder
impl TailwindBuilder
sourcepub fn trace(&mut self, style: &str) -> String
pub fn trace(&mut self, style: &str) -> String
Inline mode(no bundle)
Returns
- Anonymous style sheets, which can be placed inside
style
tags
Example
- input
<div class="p-auto px-px pt-2 pb-2">Test</div>
- output
<div class="p-auto px-px pt-2 pb-2">Test</div>
<style> {} </style>
sourcepub fn try_trace(&mut self, style: &str) -> Result<String>
pub fn try_trace(&mut self, style: &str) -> Result<String>
Safe version of TailwindBuilder::trace
sourcepub fn scope(&self, style: &str)
pub fn scope(&self, style: &str)
Inline mode(no bundle)
Returns
- Anonymous style sheets, which can be placed inside
style
tags
Example
- input
<div class="p-auto px-px pt-2 pb-2">Test</div>
- output
<div class="p-auto px-px pt-2 pb-2">Test</div>
<style> {} </style>
sourcepub fn try_scope()
pub fn try_scope()
Safe version of TailwindBuilder::scope
sourcepub fn dataset()
pub fn dataset()
Inline mode(no bundle)
Returns
- Anonymous style sheets, which can be placed inside
style
tags
Example
- input
<div class="p-auto px-px pt-2 pb-2">Test</div>
- output
<div class="p-auto px-px pt-2 pb-2">Test</div>
<style> {} </style>
sourcepub fn inline(&self, style: &str) -> String
pub fn inline(&self, style: &str) -> String
Inline mode(no bundle)
Returns
- Anonymous style sheets, which can be placed inside
style
tags
Example
- input
<div class="p-auto px-px pt-2 pb-2">Test</div>
- output
<div class="p-auto px-px pt-2 pb-2">Test</div>
<style> {} </style>
sourcepub fn try_inline(&self, style: &str) -> Result<String>
pub fn try_inline(&self, style: &str) -> Result<String>
Safe version of TailwindBuilder::inline
sourcepub fn try_bundle(&self, cap: usize) -> Result<String>
pub fn try_bundle(&self, cap: usize) -> Result<String>
Safe version of TailwindBuilder::bundle
Trait Implementations
sourceimpl Debug for TailwindBuilder
impl Debug for TailwindBuilder
Auto Trait Implementations
impl !RefUnwindSafe for TailwindBuilder
impl !Send for TailwindBuilder
impl !Sync for TailwindBuilder
impl Unpin for TailwindBuilder
impl !UnwindSafe for TailwindBuilder
Blanket Implementations
impl<T> ArchivePointee for T
impl<T> ArchivePointee for T
type ArchivedMetadata = ()
type ArchivedMetadata = ()
The archived version of the pointer metadata for this type.
pub fn pointer_metadata(
&<T as ArchivePointee>::ArchivedMetadata
) -> <T as Pointee>::Metadata
pub fn pointer_metadata(
&<T as ArchivePointee>::ArchivedMetadata
) -> <T as Pointee>::Metadata
Converts some archived metadata to the pointer metadata for itself.
sourceimpl<T> BorrowMut<T> for T where
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
const: unstable · sourcepub fn borrow_mut(&mut self) -> &mut T
pub fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more