Skip to content

align_continuous_rect_table_field and align_continuous_assign_statement do not work #201

Open

Description

@playbahn

align_continuous_rect_table_field and align_continuous_assign_statement do not work.

I'm using luals which uses this formatter, config:

lua_ls = {
    -- cmd = { ... },
    -- filetypes = { ... },
    -- capabilities = {},
    settings = {
        Lua = {
            format = {
                enable = true,
                defaultConfig = {
                    indent_style = "space",
                    indent_size = "4",
                    quote_style = "double",
                    max_line_length = "100",
                    trailing_table_separator = "smart",
                    call_arg_parenthesis = "remove",
                    space_after_comment_dash = "true",
                    align_continuous_assign_statement = "true",
                    align_continuous_rect_table_field = "true",
                },
            },
            completion = {
                callSnippet = "Replace",
            },
            diagnostics = { disable = { "missing-fields" } },
        },
    },
},

align_continuous_rect_table_field and align_continuous_assign_statement are turned on by default as per the docs, but still explicitly set them.

Screencast_2025-07-14_11.48.25.mp4

Activity

  1. CppCXY commented on Jul 21, 2025

    @CppCXY
    Owner

    set align_continuous_assign_statement = always
    set align_continuous_rect_table_field = always
    Setting these to true is not a positive action; it will check whether, in consecutive statements, the distance between the equals sign and the element on the left exceeds 1 in any case. The reason for this is that not all statements should be aligned.

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

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