Skip to content

Commit 6ee1515

Browse files
committed
Initial commit
0 parents  commit 6ee1515

15 files changed

+1269
-0
lines changed

.editorconfig

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,15 @@
1+
root = true
2+
3+
[*]
4+
indent_style = space
5+
indent_size = 4
6+
end_of_line = lf
7+
charset = utf-8
8+
trim_trailing_whitespace = true
9+
insert_final_newline = true
10+
11+
[*.{json,remarkrc,eslintrc,sh}]
12+
indent_size = 2
13+
14+
[*.md]
15+
trim_trailing_whitespace = false

.eslintignore

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
coverage/
2+
example.js
3+
hastscript.js
4+
hastscript.min.js

.eslintrc

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
{
2+
"extends": "eslint:recommended",
3+
"rules": {
4+
"quotes": [2, "single"]
5+
}
6+
}

.gitignore

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
.DS_Store
2+
*.log
3+
coverage/
4+
node_modules/
5+
hastscript.js
6+
hastscript.min.js

.jscs.json

Lines changed: 35 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,35 @@
1+
{
2+
"excludeFiles": [
3+
"coverage/",
4+
"node_modules/",
5+
"hastscript.js",
6+
"hastscript.min.js"
7+
],
8+
"preset": "yandex",
9+
"requireQuotedKeysInObjects": true,
10+
"disallowQuotedKeysInObjects": false,
11+
"maximumLineLength": {
12+
"value": 79,
13+
"allExcept": [
14+
"regex",
15+
"urlComments"
16+
]
17+
},
18+
"jsDoc": {
19+
"checkAnnotations": "jsdoc3",
20+
"checkParamExistence": true,
21+
"checkParamNames": true,
22+
"checkRedundantAccess": true,
23+
"checkRedundantParams": true,
24+
"checkRedundantReturns": true,
25+
"checkReturnTypes": true,
26+
"checkTypes": "strictNativeCase",
27+
"enforceExistence": true,
28+
"requireHyphenBeforeDescription": true,
29+
"requireNewlineAfterDescription": true,
30+
"requireParamDescription": true,
31+
"requireParamTypes": true,
32+
"requireReturnDescription": true,
33+
"requireReturnTypes": true
34+
}
35+
}

.remarkrc

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
{
2+
"output": true,
3+
"plugins": [
4+
"comment-config",
5+
"github",
6+
"lint",
7+
"usage",
8+
"validate-links"
9+
],
10+
"settings": {
11+
"bullet": "*"
12+
}
13+
}

.travis.yml

Lines changed: 26 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,26 @@
1+
language: node_js
2+
node_js:
3+
- '0.10'
4+
- '0.11'
5+
- '0.12'
6+
- '4.0'
7+
- '5.0'
8+
- iojs
9+
sudo: false
10+
after_script: npm install codecov.io && cat ./coverage/lcov.info | codecov
11+
deploy:
12+
- provider: npm
13+
14+
api_key:
15+
secure: l2iOveDemDpIVr8+8OFm+3yKUz7ix1r0v6Izy4XHegV/6X5PAFws6PEyDSFZvwhq2ROx8vSxXgDiRykdbIMWQSHYEbF8pF4RZPjIl+qO/Mn+aIqYErHDT8y8/UHfTzVR9ZJhr+3kfdA//Slu1GQUpc2cNahttZ5YCUeeafSEFkf6bNOZSV2/R9zneAnEc6Rdhif4y6TInNKFUsFzn0i5vz0MgS/NCecpsONKpGzK8xXz/yppr6kJGOJDkVi0WVIBnGC9tpu1oITb1rRpl6p+3sKFpc0+QoNNkFPol9SUFIZSNazTfNH2r6TpkGLZP37n28vFiXiurrLUsVZ2fSZMZaJLcNrGUe0GDPEYyVcqDohmMs2fpudCDWBiuumPaPieBGNYVARjSXZs8Fwe4bcp480JxhTdAecD2f506euSpe7q3g7cmuF14cutA51hH6lMZgHuLWS7nE0LZLwO6wtg9q0d1pFHwebxI4j9D/zXeopQ8YzkPSxqIsxZGBj8QnJWlDt0OLSwVKjXPMDr34OjY7I4LQdsiK9ChozaPbYg/WMqILOi7d4iFHE82RxIf71EAyFtvKvFclerqvB0/TwMqiy2vKJgFOikX+6v70oVWPERZ4DOO9rguDztQkSqMCJVN/0HEGVVfSJLEPspCi1CX8cU8f6cFoExJ6PDXMGJOw4=
16+
on:
17+
tags: true
18+
node: '5.0'
19+
- provider: releases
20+
api_key:
21+
secure: Kj34ePmdMrhEkSMMXUrVd1tX/0l9OnAze3cNAjeyKuFn3mSdM9DcXy7TstJb023tJQ57PIX+LDFyZCGe8vubwSfFeULZLBIyaSsaZw6wfZTkobla99f3oWm+1iGhUU7aLbH+31U4k6aEUsU2S/VtPo/TbrW6/P8wzGiWIC2j1OObnZqiB2a0UUlqEGEqsMwv/9tI/EMkx/qYN2/MJJUj1KYORMQcZCI8cv6R2XnSSZ7lHeuOsN67hB/WotZyfrihsFRY0ANT4J94ateiX2E9BFBLFtjQwa8T2JsFh8Q+Ex7otgQIegu+Jum9x8/EAUGtiopgz4PCeWCey2Ri0mywKLIl+ewQvAlX0zNjreBKNpumcPd4UKXCLQHTpPjbNjNzgGyVBT161xipx1PrCgAKlSX2PS3dydLArwOlYnE+EK8xbBCHonLsnyHrm4xSJKZk1ypeNMEd7jaxBbkFlHkvcWselIA6Y4xSjxb9szY8QlDU5oKuNzOtVZrOxHY9IXijP3aub889D4yzbtNc1oBhDFpdiPLbHO0KAo6bOzR4/kDLjm0KEOYHcmZqMDSX+YKwfOOfJEVGKTjekpi1FBoN9in6Y3piJgpkvURjp6tDMYaC9C2dBFGbhKNPNQDLSoMvfBzdemAk8AJjx6tTT9ZdmWCNcP+XjGG2vuNDZEz7sq4=
22+
file:
23+
- "hastscript.js"
24+
- "hastscript.min.js"
25+
on:
26+
tags: true

LICENSE

Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,22 @@
1+
(The MIT License)
2+
3+
Copyright (c) 2016 Titus Wormer <[email protected]>
4+
5+
Permission is hereby granted, free of charge, to any person obtaining
6+
a copy of this software and associated documentation files (the
7+
'Software'), to deal in the Software without restriction, including
8+
without limitation the rights to use, copy, modify, merge, publish,
9+
distribute, sublicense, and/or sell copies of the Software, and to
10+
permit persons to whom the Software is furnished to do so, subject to
11+
the following conditions:
12+
13+
The above copyright notice and this permission notice shall be
14+
included in all copies or substantial portions of the Software.
15+
16+
THE SOFTWARE IS PROVIDED 'AS IS', WITHOUT WARRANTY OF ANY KIND,
17+
EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
18+
MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
19+
IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
20+
CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
21+
TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
22+
SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.

example.js

Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
// Dependencies:
2+
var h = require('./index.js');
3+
4+
// AST:
5+
var tree = h('.foo#some-id', [
6+
h('span', 'some text'),
7+
h('input', {
8+
'type': 'text',
9+
'value': 'foo'
10+
}),
11+
h('a.alpha', {
12+
'class': 'bravo charlie',
13+
'style': 'color:/*red*/purple',
14+
'download': 'download'
15+
}, ['delta', 'echo'])
16+
]);
17+
18+
// Yields:
19+
console.log('js', require('util').inspect(tree, {'depth': null}));

history.md

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
<!--remark setext-->
2+
3+
<!--lint disable no-multiple-toplevel-headings -->
4+
5+
0.0.0 / 2016-02-24
6+
==================

0 commit comments

Comments
 (0)