🔥 amazing PR just merged from @wlls.dev using @deno.land's docs package to generate docs for any package on the npm registry ....
Post
Thank you!! Lots of fun directions we can take this, and I'm sure I missed some edge cases. Real heavy lifting here and shoutout goes to the @deno.land folks for providing the underlying tooling. All I did was a little glue code really.
pretty naively in this first pass! i'm basically: 1. fetching type urls from esh.sh with an `x-typescript-types` header 2. run it `@deno/doc` slightly patched to get WASM to work on a vercel function 3. take the `DenoDocNode[]` structured AST result 4. flatten, transform, merge, render to HTML
if interested what it actually does, you can take a look at github.com/denoland/den..., all rust code in this directory is what is used for processing the docnodes to make them into the output of generateHTMLasJSON
wow yeah 90% of what I was doing working on this was fixing edge cases (and there appear to still be more) not sure i'm happy or sad that i missed this earlier haha (it was fun reading the doc AST! but yeah wow...) will play with this later and see if i can massage it back into looking similar!
0 reposts2 likes
No replies yet.