Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

📝 useSortedClasses removes spaces between computed variables #3790

Closed
1 task done
theogravity opened this issue Sep 5, 2024 · 3 comments
Closed
1 task done

📝 useSortedClasses removes spaces between computed variables #3790

theogravity opened this issue Sep 5, 2024 · 3 comments

Comments

@theogravity
Copy link

theogravity commented Sep 5, 2024

Environment information

flex flex-shrink-0 flex-row items-center font-medium ${props.className} ${buttonColor} ${buttonSize}

becomes

flex flex-shrink-0 flex-row items-center font-medium ${props.className}${buttonColor}${buttonSize}

(there's no space between the computed items)

Note: I don't know how to enable useSortedClasses in the playground, so the playground link has the code, but the formatted ver is fine because it's not enabled.

Configuration

{
  "$schema": "https://biomejs.dev/schemas/1.8.3/schema.json",
  "organizeImports": {
    "enabled": true
  },
  "formatter": {
    "enabled": true,
    "indentStyle": "space",
    "lineWidth": 120,
    "ignore": [
      "node_modules/*",
      "*.config.*",
      "*.json",
      "tsconfig.json",
      ".turbo/*",
      ".next/*",
      "dist/*",
      ".pnpm-store/*"
    ]
  },
  "linter": {
    "enabled": true,
    "ignore": ["dist/*", ".pnpm-store/*", "packages/portal-client/*", ".next/*", ".turbo/*"],
    "rules": {
      "a11y": {
        "noSvgWithoutTitle": "off"
      },
      "performance": {
        "noDelete": "off"
      },
      "complexity": {
        "useLiteralKeys": "off",
        "noStaticOnlyClass": "off"
      },
      "correctness": {
        "noUnusedImports": "error",
        "useExhaustiveDependencies": "warn"
      },
      "suspicious": {
        "noImplicitAnyLet": "off",
        "noExplicitAny": "off",
        "noDebugger": {
          "level": "warn",
          "fix": "none"
        }
      },
      "nursery": {
        "useSortedClasses": "warn"
      },
      "recommended": true
    }
  }
}

Playground link

https://biomejs.dev/playground/?code=aQBtAHAAbwByAHQAIAB0AHkAcABlACAAUgBlAGEAYwB0ACAAZgByAG8AbQAgACIAcgB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AcwBwAGEAbgA%2BAH0ACgAgACAAIAAgACAAIAA8AHMAcABhAG4AIABjAGwAYQBzAHMATgBhAG0AZQA9AHsAYAAkAHsAdABlAHgAdABTAGkAegBlAH0AIABmAGwAZQB4AC0AZwByAG8AdwAgAHQAZQB4AHQALQBjAGUAbgB0AGUAcgAgAGYAbwBuAHQALQBuAG8AcgBtAGEAbABgAH0APgB7AHQAZQB4AHQAfQA8AC8AcwBwAGEAbgA%2BAAoAIAAgACAAIAAgACAAewBSAGkAZwBoAHQASQBjAG8AbgAgACYAJgAgADwAcwBwAGEAbgAgAGMAbABhAHMAcwBOAGEAbQBlAD0AIgBtAGwALQAyACAAZgBsAGUAeAAgAGkAdABlAG0AcwAtAGMAZQBuAHQAZQByACIAPgB7AFIAaQBnAGgAdABJAGMAbwBuAH0APAAvAHMAcABhAG4APgB9AAoAIAAgACAAIAA8AC8AYgB1AHQAdABvAG4APgAKACAAIAApADsACgB9ADsACgAKAGUAeABwAG8AcgB0ACAAZABlAGYAYQB1AGwAdAAgAEIAdQB0AHQAbwBuADsACgA%3D

Code of Conduct

  • I agree to follow Biome's Code of Conduct
@ematipico
Copy link
Member

@theogravity can you please update the playground link:

  • enable all rules
  • remove all the code that's not needed to identify the bug

@hangaoke1
Copy link
Contributor

hangaoke1 commented Nov 11, 2024

repeat #4041

@ematipico
Copy link
Member

I am going to close the issue for now. It seems it was fixed

@ematipico ematipico closed this as not planned Won't fix, can't repro, duplicate, stale Nov 11, 2024
@ematipico ematipico reopened this Nov 11, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants