Skip to content
This repository was archived by the owner on Aug 28, 2026. It is now read-only.
This repository was archived by the owner on Aug 28, 2026. It is now read-only.

Override :local(.class) rules from external less file #564

Closed

Description

@serbanghita

I have a project using less 2.7.1 and css-loader 0.23.1.
webpack version is 2.3.2.

In my project I have a component with the name MyComponent incorporates a 3rd party component imported from node_modules, called WysiwygComponent.
WysiwygComponent has the style rules in WysiwygComponent.less:

:local(.wrap) {
 font-size: 18px;
}

this generates a CSS rule like WysiwygComponent--wrap--MhELi.

In MyComponent i have MyComponent.less file I want to override the WysiwygComponent--wrap by using something like: .MyComponent-wrap .WysiwygComponent-wrap { ... }.

Unfortunately I found no way to extend/override the CSS with :local(.wrap) syntax inside MyComponent.less

Activity

  1. TrySound commented on Jun 28, 2017

    @TrySound
    Contributor

    It's WIP
    #562

  2. alexander-akait commented on Feb 15, 2018

    @alexander-akait
    Member

    @TrySound problem was solved?

  3. TrySound commented on Feb 15, 2018

    @TrySound
    Contributor

    It can't be solved without major release.
    /cc @michael-ciniawsky

  4. alexander-akait commented on Feb 15, 2018

    @alexander-akait
    Member

    @TrySound it is solved in new version postcss-* plugins?

  5. TrySound commented on Feb 15, 2018

    @TrySound
    Contributor

    Maybe. However current idea is to combine all plugins in one to prevent compatibility problem between plugins.

  6. alexander-akait commented on Feb 15, 2018

    @alexander-akait
    Member
  7. TrySound commented on Feb 15, 2018

    @TrySound
    Contributor

    @evilebottnawi Nope. It's just a pack. I mean full rewrite in single plugin. This can solve all problems.

  8. alexander-akait commented on Feb 15, 2018

    @alexander-akait
    Member

    @TrySound somebody can take care about this?

  9. TrySound commented on Feb 15, 2018

    @TrySound
    Contributor

    We need to decide. Do we focus on webpack css type support, or do we finish this and fix everything with breaking change.

  10. alexander-akait commented on Feb 15, 2018

    @alexander-akait
    Member

    @TrySound Roadmap:

    1. Stability current style-loader/css-loader/postcss-loader with support css-modules and webpack@4
    2. Experimental branch with css in webpack

    It is allow to easy migrate and improve stability loaders. Experimental branch can take a long time, we must give people the opportunity to work stably.

  11. alexander-akait commented on Dec 3, 2018

    @alexander-akait
    Member

    Closing due to inactivity. Please test with latest version and feel free to reopen if still regressions. Thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Fields

    Priority

    None yet

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions