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

Rules for HTML Linting #13

Open
gaurav21r opened this issue Mar 3, 2016 · 3 comments
Open

Rules for HTML Linting #13

gaurav21r opened this issue Mar 3, 2016 · 3 comments
Assignees
Labels

Comments

@gaurav21r
Copy link
Member

@riteshe63 as you had mentioned in #4 I agree https://github.com/yaniswang/HTMLHint seems to be the best.

It seems to be quite difficult to find default configurations for HTML as compared to the variety of options in JS #6 .

With the advent of HTML Web Components and projects focused on HTML its quite surprising none of the big ones use an .htmlhintrc.

Maybe no one just cares how HTML is linted? :(

Tracking info from HTMLHint themselves here htmlhint/HTMLHint#112
Tracking request to Polymer here Polymer/polymer#3490
Tracking request to HTML5 Boilerplate here h5bp/html5-boilerplate#1801

cc @prakash1517 @riteshe63 @nitinmadeshia

@gaurav21r gaurav21r self-assigned this Mar 3, 2016
@gaurav21r
Copy link
Member Author

@riteshe63 Please use the following rules for the time being:

{
  "tagname-lowercase": true,
  "attr-lowercase": true,
  "attr-value-double-quotes": true,
  "doctype-first": true,
  "tag-pair": true,
  "spec-char-escape": true,
  "id-unique": true,
  "src-not-empty": true,
  "attr-no-duplication": true,
  "title-require": true,
  "tag-self-close": true,
  "alt-require": true,
  "doctype-html5": true,
  "space-tab-mixed-disabled": "space",
  "id-class-ad-disabled": true,
  "attr-unsafe-chars": true
}

There are still more things to be done:

  1. Make an htmlhintrc based on HTML5Bootstrap
  2. Make htmlhint lint indentation errors.

We need to open separate issues for both of these. Lets not close this until we've opened those.

@riteshe63
Copy link
Contributor

#28
Solve this issue

@gaurav21r
Copy link
Member Author

We've got positive response for the h5bp team h5bp/html5-boilerplate#1801 (comment)

@divya3103 We should now open a PR there and continue with this issue.

@riteshe63 riteshe63 mentioned this issue Nov 8, 2016
6 tasks
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants