Skip to content

Simple attribute indentation fails with codemod mock#94

Open
tylerturdenpants wants to merge 3 commits intoember-template-lint:masterfrom
tylerturdenpants:attrs-on-same-line
Open

Simple attribute indentation fails with codemod mock#94
tylerturdenpants wants to merge 3 commits intoember-template-lint:masterfrom
tylerturdenpants:attrs-on-same-line

Conversation

@tylerturdenpants
Copy link
Copy Markdown
Contributor

@tylerturdenpants tylerturdenpants commented Aug 16, 2019

Small example of #84 using existing test.

Copy link
Copy Markdown
Member

@rwjblue rwjblue left a comment

Choose a reason for hiding this comment

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

FWIW, this is less of a bug per-se and more of a missing feature. When creating the new ElementNode we have no way to figure out what “join” mechanism (e.g. \n vs ) to use so we default to .

We should definitely give an api for this (or try to discern a default from the rest of the template).

Comment thread tests/smoke-test.js Outdated
@tylerturdenpants
Copy link
Copy Markdown
Contributor Author

When I inspect the newly created nodes I do see location information that seems to reference its old location. What's going on there?

@tylerturdenpants
Copy link
Copy Markdown
Contributor Author

I guess the location info is useless if you dont know what "join" mechanism is?

@tylerturdenpants
Copy link
Copy Markdown
Contributor Author

I think its time for an API for this since this is the last major hurdle to release the angle-bracket-codemod using ember-template-recat

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

Successfully merging this pull request may close these issues.

2 participants