-
-
Notifications
You must be signed in to change notification settings - Fork 27
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Require Node.js 8, add TypeScript definition (#3)
- Loading branch information
1 parent
cb1d76e
commit 9541b58
Showing
10 changed files
with
94 additions
and
41 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,2 +1 @@ | ||
* text=auto | ||
*.js text eol=lf | ||
* text=auto eol=lf |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1 +1,2 @@ | ||
node_modules | ||
yarn.lock |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
package-lock=false |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,4 @@ | ||
language: node_js | ||
node_js: | ||
- '10' | ||
- '8' | ||
- '6' | ||
- '4' |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
declare const voidHtmlTags: readonly string[]; | ||
|
||
export = voidHtmlTags; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
declare const htmlTags: readonly string[]; | ||
|
||
export = htmlTags; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
/** | ||
List of standard HTML tags. | ||
@example | ||
``` | ||
import htmlTags = require('html-tags'); | ||
console.log(htmlTags); | ||
//=> ['a', 'abbr', 'acronym', ...] | ||
``` | ||
*/ | ||
declare const htmlTags: readonly string[]; | ||
|
||
export = htmlTags; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
import {expectType, expectError} from 'tsd'; | ||
import htmlTags = require('.'); | ||
import voidHtmlTags = require('./void'); | ||
import htmlTagsJson = require('./html-tags.json'); | ||
import voidHtmlTagsJson = require('./html-tags-void.json'); | ||
|
||
expectType<readonly string[]>(htmlTags); | ||
expectError(htmlTags.push("")); | ||
expectType<readonly string[]>(voidHtmlTags); | ||
expectError(voidHtmlTags.push("")); | ||
expectType<readonly string[]>(htmlTagsJson); | ||
expectError(htmlTagsJson.push("")); | ||
expectType<readonly string[]>(voidHtmlTagsJson); | ||
expectError(voidHtmlTagsJson.push("")); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,39 +1,44 @@ | ||
{ | ||
"name": "html-tags", | ||
"version": "2.0.0", | ||
"description": "List of standard HTML tags", | ||
"license": "MIT", | ||
"repository": "sindresorhus/html-tags", | ||
"author": { | ||
"name": "Sindre Sorhus", | ||
"email": "[email protected]", | ||
"url": "sindresorhus.com" | ||
}, | ||
"engines": { | ||
"node": ">=4" | ||
}, | ||
"scripts": { | ||
"test": "xo && ava" | ||
}, | ||
"files": [ | ||
"index.js", | ||
"void.js", | ||
"html-tags.json", | ||
"html-tags-void.json" | ||
], | ||
"keywords": [ | ||
"html", | ||
"html5", | ||
"tags", | ||
"elements", | ||
"list", | ||
"whatwg", | ||
"w3c", | ||
"void", | ||
"self-closing" | ||
], | ||
"devDependencies": { | ||
"ava": "*", | ||
"xo": "*" | ||
} | ||
"name": "html-tags", | ||
"version": "2.0.0", | ||
"description": "List of standard HTML tags", | ||
"license": "MIT", | ||
"repository": "sindresorhus/html-tags", | ||
"author": { | ||
"name": "Sindre Sorhus", | ||
"email": "[email protected]", | ||
"url": "sindresorhus.com" | ||
}, | ||
"engines": { | ||
"node": ">=8" | ||
}, | ||
"scripts": { | ||
"test": "xo && ava && tsd" | ||
}, | ||
"files": [ | ||
"index.js", | ||
"index.d.ts", | ||
"void.js", | ||
"void.d.ts", | ||
"html-tags.json", | ||
"html-tags.json.d.ts", | ||
"html-tags-void.json", | ||
"html-tags-void.json.d.ts" | ||
], | ||
"keywords": [ | ||
"html", | ||
"html5", | ||
"tags", | ||
"elements", | ||
"list", | ||
"whatwg", | ||
"w3c", | ||
"void", | ||
"self-closing" | ||
], | ||
"devDependencies": { | ||
"ava": "^1.4.1", | ||
"tsd": "^0.7.2", | ||
"xo": "^0.24.0" | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
/** | ||
List of void (self-closing) HTML tags. | ||
@example | ||
``` | ||
import voidHtmlTags = require('html-tags/void'); | ||
console.log(voidHtmlTags); | ||
//=> ['area', 'base', 'br', ...] | ||
``` | ||
*/ | ||
declare const voidHtmlTags: readonly string[]; | ||
|
||
export = voidHtmlTags; |