Skip to content

Conversation

mrmlnc
Copy link
Member

@mrmlnc mrmlnc commented Feb 12, 2017

Source

mrmlnc/vscode-attrs-sorter#29

Documentation

https://github.com/fb55/htmlparser2/wiki/Parser-options#option-lowercaseattributenames

Description

IMHO, should be disabled by default.

<a routerLink="/home">Home</a>

Before

// ------------------------ \/
[ { tag: 'a', attrs: { routerlink: '/home' }, content: [ 'Home' ] },
  options: {},
  processor: PostHTML { version: '0.9.2', name: 'posthtml', plugins: [ [Function] ] },

  walk: [Function: walk],
  match: [Function: match] ]

After

// ------------------------ \/
[ { tag: 'a', attrs: { routerLink: '/home' }, content: [ 'Home' ] },
  options: {},
  processor: PostHTML { version: '0.9.2', name: 'posthtml', plugins: [ [Function] ] },

  walk: [Function: walk],
  match: [Function: match] ]

/cc @voischev @michael-ciniawsky

@coveralls
Copy link

Coverage Status

Coverage remained the same at 100.0% when pulling 2145089 on mrmlnc:lowerCaseAttributeNames into bf7395e on posthtml:master.

1 similar comment
@coveralls
Copy link

coveralls commented Feb 12, 2017

Coverage Status

Coverage remained the same at 100.0% when pulling 2145089 on mrmlnc:lowerCaseAttributeNames into bf7395e on posthtml:master.

Copy link
Member

@michael-ciniawsky michael-ciniawsky left a comment

Choose a reason for hiding this comment

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

If it doesn't effect anyone, I would say 👍

@mrmlnc
Copy link
Member Author

mrmlnc commented Feb 13, 2017

If it doesn't effect anyone, I would say 👍

@michael-ciniawsky

Yeap, works only for attributes 👻

https://github.com/fb55/htmlparser2/blob/d8d07fbd8441c62ac299fc3c9b113a088b70b49b/lib/Parser.js#L231-L236

@voischev voischev self-requested a review February 14, 2017 10:55
@voischev
Copy link
Member

👍

@voischev voischev merged commit e0fb739 into posthtml:master Feb 14, 2017
@mrmlnc
Copy link
Member Author

mrmlnc commented Feb 14, 2017

Tag 0.2.1 and I'll be happy 🐼

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.

4 participants