#[non_exhaustive]pub struct TransformModuleCssModuleContextV0 {
pub module_instance: ModuleInstanceKeyV0,
pub class_name_rewrites: Vec<TransformClassNameRewriteV0>,
pub composes_resolutions: Vec<TransformCssModuleComposesResolutionV0>,
}Expand description
Module-qualified CSS Modules rewrite input.
Consumers that need different rewrites for identical class spellings in
different modules use this carrier instead of flattening those rewrites
into TransformExecutionContextV0::class_name_rewrites. The module key is
compared before the canonical class-name key. Under an equal compound key,
the consumer-supplied record is the first witness and wins independently of
raw spelling or later presentation sorting.
Fields (Non-exhaustive)§
This struct is marked as non-exhaustive
Non-exhaustive structs could have additional fields added in future. Therefore, non-exhaustive structs cannot be constructed in external crates using the traditional
Struct { .. } syntax; cannot be matched against without a wildcard ..; and struct update syntax will not work.module_instance: ModuleInstanceKeyV0§class_name_rewrites: Vec<TransformClassNameRewriteV0>§composes_resolutions: Vec<TransformCssModuleComposesResolutionV0>Implementations§
Source§impl TransformModuleCssModuleContextV0
impl TransformModuleCssModuleContextV0
pub fn new(module_instance: ModuleInstanceKeyV0) -> Self
pub fn with_class_name_rewrites( self, class_name_rewrites: Vec<TransformClassNameRewriteV0>, ) -> Self
pub fn with_composes_resolutions( self, composes_resolutions: Vec<TransformCssModuleComposesResolutionV0>, ) -> Self
Trait Implementations§
Source§impl Clone for TransformModuleCssModuleContextV0
impl Clone for TransformModuleCssModuleContextV0
Source§fn clone(&self) -> TransformModuleCssModuleContextV0
fn clone(&self) -> TransformModuleCssModuleContextV0
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl<'de> Deserialize<'de> for TransformModuleCssModuleContextV0
impl<'de> Deserialize<'de> for TransformModuleCssModuleContextV0
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
impl Eq for TransformModuleCssModuleContextV0
impl StructuralPartialEq for TransformModuleCssModuleContextV0
Auto Trait Implementations§
impl Freeze for TransformModuleCssModuleContextV0
impl RefUnwindSafe for TransformModuleCssModuleContextV0
impl Send for TransformModuleCssModuleContextV0
impl Sync for TransformModuleCssModuleContextV0
impl Unpin for TransformModuleCssModuleContextV0
impl UnsafeUnpin for TransformModuleCssModuleContextV0
impl UnwindSafe for TransformModuleCssModuleContextV0
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> DeserializeOwned for Twhere
T: for<'de> Deserialize<'de>,
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key and return true if they are equal.