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

Shorthand generator functions are formatting strangely #941

Closed
jgeurts opened this issue May 24, 2016 · 3 comments
Closed

Shorthand generator functions are formatting strangely #941

jgeurts opened this issue May 24, 2016 · 3 comments
Milestone

Comments

@jgeurts
Copy link
Contributor

jgeurts commented May 24, 2016

var foo = {
    * bar() {
        yield 42;
    }
};

gets formatted like:

var foo = { *
    bar() {
        yield 42;
    }
};

Similarly,

var foo = {
    bar() {
        return 42;
    },
    * barGen() {
        yield 42;
    }
};

is formatted as:

var foo = {
    bar() {
        return 42;
    },
    *
    barGen() {
        yield 42;
    }
};

Ideally, the star should be on the same line as the generator name, with a space between the star and the generator name

@mastephens
Copy link

I would definitely like to see this issue resolved.
Thanks!
Mike

@bitwiseman
Copy link
Member

@mastephens - I'm sorry, my time if very limited currently. Any help you can provide would be great!

@bitwiseman bitwiseman added this to the v1.6.4 milestone Aug 8, 2016
@jgeurts
Copy link
Contributor Author

jgeurts commented Aug 30, 2016

Awesome, thank you!

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

No branches or pull requests

3 participants