Skip to content

Properties order not maintained #572

@GrandSchtroumpf

Description

@GrandSchtroumpf

It seems that the order of properties are not maintained when bundle with lightning css.

With this input :

.item {
  animation: fade both;
  animation-timeline: scroll(root block);
}

I've got this output :

.item {
  animation-timeline: scroll(root block);
  animation: fade both;
}

The issue is that animation will override animation-timeline, so it'll not work.

I'm using vite with this config :

return {
    build: {
      cssMinify: 'lightningcss' as const,
    },
    css: {
      transformer: 'lightningcss' as const,
      lightningcss: {
        drafts: {
          nesting: true,
          customMedia: true
        }
      },
    }
}

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions