-
Notifications
You must be signed in to change notification settings - Fork 32
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
Use ember-template-recast
to preserve existing template formatting as much as possible
#97
Conversation
@tylerturdenpants - 👋 how are things going here? Would you have any time to do a quick brain dump on the current status? |
@rwjblue I said this in st-octane:
The issuses mentioned have solutions and are relatively minor. We can chat more if you like. |
18cbbf9
to
e190d5a
Compare
ember-template-recast
to keep existing template formatting
e190d5a
to
6f9e112
Compare
</bg.button> | ||
</BsButtonGroup>" | ||
" | ||
<BsButtonGroup @value={{buttonGroupValue}} @type=\\"checkbox\\" @onChange={{action (mut buttonGroupValue)}} as |bg|> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can you open an issue specifically about coordinating with ember-template-recast to create an API to allow a transform to customize whitespace for newly created nodes (in the case of this test, the whitespace cannot be inferred because its a fully new ElementNode) then leave an inline comment with a link to that issue?
I'll mention linking to the "new node whitespace preservation issue" in a few other spots as I notice them.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This issue ember-template-lint/ember-template-recast#82 has us discussing the above. Can I use this issue for the comment or would you like a new one created?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ya, that seems great to link to. I mostly wanted to notate inline that we intend for this output to be changed in the future (once the issue has been fixed/released).
@@ -162,31 +163,17 @@ test('deeply-nested-sub', () => { | |||
`; | |||
|
|||
expect(runTest('deeply-nested-sub.hbs', input)).toMatchInlineSnapshot(` |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can you comment RE: the new node whitespace preservation issue here as well?
@@ -378,34 +363,12 @@ test('link-to-inline', () => { | |||
`; | |||
|
|||
expect(runTest('link-to-inline.hbs', input)).toMatchInlineSnapshot(` |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can you comment RE: the new node whitespace preservation issue here as well?
<LinkTo @query={{hash direction=\\"desc\\" showArchived=false}}> | ||
Recent Posts | ||
</LinkTo> | ||
<LinkTo @route=\\"apps.app.users.segments.segment\\" @model=\\"all-users\\" @query={{hash searchTerm=searchTerm}}>Users</LinkTo> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can you comment RE: the new node whitespace preservation issue here as well?
94ac02e
to
e93e55e
Compare
ember-template-recast
to keep existing template formatting ember-template-recast
to preserve existing template formatting as much as possible
refactors to ease modification and to support ember template recast a bit better