-
Notifications
You must be signed in to change notification settings - Fork 4
Conversation
Codecov Report
@@ Coverage Diff @@
## next #77 +/- ##
=======================================
Coverage 91.05% 91.05%
=======================================
Files 3 3
Lines 123 123
Branches 34 34
=======================================
Hits 112 112
Misses 11 11
Continue to review full report at Codecov.
|
src/scripts/docs.ts
Outdated
let readme = await readFile(readmePath, 'utf8') | ||
|
||
readme = await themeDocs(readme) | ||
readme = await extsDocs(readme) | ||
readme = await apiDocs(readme) | ||
|
||
await writeFile(readmePath, readme) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Stylistic suggestion: might be idiomatic promise-wise to have something like:
const readme = readFile(readmePath, 'utf8')
.then(themeDocs)
.then(extsDocs)
.then(apiDocs)
.catch(/*handle the error*/)
perhaps renaming the function names with a generate
prefix?
If the three doc generation functions don't need to run sequentially(?), Promise.all
might be a candidate here.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks David, good suggestions (that reassignment definitely didn't feel right but I didn't stop to think how it could be done better 🙂 ).
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
📚👍
🎉 This PR is included in version 1.8.0 🎉 The release is available on: Your semantic-release bot 📦🚀 |
Completes the first bullet point of #71.
Also add autogeneration of a table of themes (but not documentation around that).