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

Bad indentation when editing elm file #193

Open
YievCkim opened this issue May 8, 2024 · 0 comments
Open

Bad indentation when editing elm file #193

YievCkim opened this issue May 8, 2024 · 0 comments

Comments

@YievCkim
Copy link

YievCkim commented May 8, 2024

When I am editing an elm file in elm mode. Elm-mode does not indent the text properly.

By example this (which is obtained at the beginning just after hitting enter at the end of the previous line) :

        case x of
            Just something -> 
                    Html.button
                        [ HtmlE.onClick Msg
                        , HtmlA.class "a_class"
                        ]
                    [ Html.text something ]

Hitting tab do that:

        case x of
            Just something -> 
                    Html.button
                        [ HtmlE.onClick Msg
                        , HtmlA.class "a_class"
                        ]
            [ Html.text something ]

or that:

        case x of
            Just something -> 
                    Html.button
                        [ HtmlE.onClick Msg
                        , HtmlA.class "a_class"
                        ]
        [ Html.text something ]

But never this:

        case x of
            Just something -> 
                    Html.button
                        [ HtmlE.onClick Msg
                        , HtmlA.class "a_class"
                        ]
                        [ Html.text something ]

Which is what is excepted and what elm-format does.
It's a bit annoying to use elm-format every time for that.

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

1 participant