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

Typescript indent failing for multiline properties #141

Open
z0rzi opened this issue Oct 4, 2020 · 0 comments
Open

Typescript indent failing for multiline properties #141

z0rzi opened this issue Oct 4, 2020 · 0 comments

Comments

@z0rzi
Copy link

z0rzi commented Oct 4, 2020

Hi there!

Here's an example of a template where the problem occurs:

        <div className={`
            bg-white
            min-h-full
            font-sans
            text-black
            py-16 lg:py-40
            p-8 md:p-12 lg:p-0
            lg:pl-24
        `}>
            <Intro />
            <div className={`
                container
                mx-auto
            `}>
                <Education />
            </div>
        </div>

When I try indenting in Typescript, all the properties in the back tick fall to column 0. The same thing happens with the following:

        <div className={
            "bg-white "+
            "min-h-full "+
            "font-sans "+
            "text-black "+
            "py-16 lg:py-40 "+
            "p-8 md:p-12 lg:p-0 "+
            "lg:pl-24 "
        }>
            <Intro />
            <div className={
                "container "+
                "mx-auto "
            }>
                <Education />
            </div>
        </div>

Note that this problem doesn't occur in javascript. So to solve it, I just need to run set ft=javascriptreact, but then I don't have the typescript syntax.

Thanks!

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