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

Add autofixer to simple-unless rule for simplest case #2629

Merged
merged 1 commit into from
Oct 10, 2022

Conversation

godric3
Copy link
Contributor

@godric3 godric3 commented Oct 9, 2022

Part of #2571.

For start auto fix for simplest case of:

{{#unless condition}}
  A
{{else}}
  B
{{/unless}}

fixed to

{{#if condition}}
  B
{{else}}
  A
{{/if}}

For other cases I will need to dive more into ast manipulations

@bmish bmish changed the title Add auto fix for simple-unless simplest case Add autofix to simple-unless rule for simplest case Oct 10, 2022
@bmish bmish changed the title Add autofix to simple-unless rule for simplest case Add autofixer to simple-unless rule for simplest case Oct 10, 2022
Copy link
Member

@bmish bmish left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Awesome, thanks!

@bmish bmish merged commit 8f11e0d into ember-template-lint:master Oct 10, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants