Skip to content

Can we have line breaks? #67

@Malien

Description

@Malien

Thanks for the project!

It is unpopular in tailwind circles to space out class names onto multiple lines. But for me it makes navigating the code MUCH easier. (especially in vim)

<button
  class=" flex-none cursor-pointer rounded border-slate-300 bg-white px-4 py-1 shadow-sm shadow-lg light:border hover:border-slate-400 active:bg-gray-100 dark:border-t dark:border-slate-500 dark:bg-slate-800 dark:shadow-indigo-950 dark:hover:bg-slate-700 dark:active:border-slate-900 dark:active:bg-slate-900 "
  id="passkey-create"
>
  Create a passkey to continue
</button>

vs

<button
  class="
    flex-none cursor-pointer rounded border-slate-300 bg-white px-4 py-1 
    shadow-sm shadow-lg light:border hover:border-slate-400 active:bg-gray-100 
    dark:border-t dark:border-slate-500 dark:bg-slate-800 dark:shadow-indigo-950
    dark:hover:bg-slate-700 dark:active:border-slate-900 dark:active:bg-slate-900
  "
  id="passkey-create"
>
  Create a passkey to continue
</button>

When it comes to interplay with class lists, the heuristics aren't simple, but is this something that is worth considering?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions