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

support align elements #21

Open
tjx666 opened this issue Jan 26, 2023 · 1 comment
Open

support align elements #21

tjx666 opened this issue Jan 26, 2023 · 1 comment
Labels
enhancement New feature or request help wanted Extra attention is needed

Comments

@tjx666
Copy link

tjx666 commented Jan 26, 2023

Scene1: one dimension array:

// now
// prettier-multiline-arrays-next-line-pattern: 2
const array2 = [
    'apple', 'meta',
    'microsoft', 'google',
    'apple', 'meta',
    'microsoft', 'google',
];

// expect every column should align left like a table
// prettier-multiline-arrays-next-line-pattern: 2, align
// prettier-ignore
const array3 = [
    'apple',     'meta',
    'microsoft', 'google',
    'apple',     'meta',
    'microsoft', 'google',
];

Scene2: multiple dimension array expected can formatted to

image

@electrovir electrovir added enhancement New feature or request help wanted Extra attention is needed labels Jan 26, 2023
@electrovir
Copy link
Owner

Cool idea! Thanks for bringing it up.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request help wanted Extra attention is needed
Projects
None yet
Development

No branches or pull requests

2 participants