File tree Expand file tree Collapse file tree 5 files changed +3734
-53
lines changed
Expand file tree Collapse file tree 5 files changed +3734
-53
lines changed Original file line number Diff line number Diff line change 11{
2- "runtime.special" : {
3- "typename" : " type"
4- }
2+ "Lua.workspace.checkThirdParty" : false ,
3+ "diagnostics.groupSeverity" : {
4+ "ambiguity" : " Error" ,
5+ "await" : " Error" ,
6+ "codestyle" : " Error" ,
7+ "duplicate" : " Hint" ,
8+ "global" : " Error" ,
9+ "luadoc" : " Error" ,
10+ "redefined" : " Information" ,
11+ "strict" : " Error" ,
12+ "strong" : " Error" ,
13+ "type-check" : " Error" ,
14+ "unbalanced" : " Error" ,
15+ "unused" : " Hint" ,
16+ "conventions" : " Error"
17+ },
18+ "diagnostics.disable" : [
19+ " duplicate-doc-alias" ,
20+ " duplicate-doc-field"
21+ ],
22+ "runtime.path" : [
23+ " ?.lua" ,
24+ " ?/init.lua" ,
25+ ],
26+ "runtime.pathStrict" : true ,
27+ "runtime.version" : " LuaJIT" ,
28+ "workspace.ignoreDir" : [
29+ " .vscode" ,
30+ " .luarocks"
31+ ],
32+ "workspace.library" : [
33+ " deps/" ,
34+ " lua_modules/lib/lua/5.1/" ,
35+ " lua_modules/share/lua/5.1/" ,
36+ ],
537}
Original file line number Diff line number Diff line change 1+ #! /usr/bin/env lua
2+
3+ local data = require (" parse-data" ) " items-raw.html"
4+
5+ --- @alias WriteFunction fun ( ... : string ): WriteFunction
6+ --- @alias WriteLineFunction fun ( ... : string ): WriteFunction
7+
8+ --- @type WriteFunction
9+ local function w (...)
10+ io.write (... )
11+ return w
12+ end
13+
14+ --- @type WriteLineFunction
15+ local function wl (...)
16+ io.write (... )
17+ io.write " \n "
18+ return wl
19+ end
20+
21+ for k , v in pairs (data ) do
22+ w " --[[# <code>" (k ) ' </code>\n '
23+
24+ wl " ## Description" (v .description ) ' \n '
25+
26+ w (# v .categories > 0 and " ## Categories" or " " )
27+ for _ , cat in ipairs (v .categories ) do
28+ w " - " (cat ) ' \n '
29+ end
30+
31+ w " ]]\n "
32+
33+
34+ w " ---@class HTMLElement." (k ) ' : ' " XML.Node\n "
35+ for _ , cat in ipairs (v .attributes ) do
36+ if cat .name == " global" then goto next end
37+ w " ---@field " (cat .name ) " any " " [Documentation](" (cat .url or " " ) " )\n "
38+ :: next::
39+ end
40+
41+ w " export.xml." (k )' =' ' export.xml.' (k ) ' \n\n '
42+ end
You can’t perform that action at this time.
0 commit comments