-
Notifications
You must be signed in to change notification settings - Fork 25
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add TSDoc, style
and className
props
#543
base: main
Are you sure you want to change the base?
Conversation
The latest updates on your projects. Learn more about Vercel for Git ↗︎
|
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 for the effort, though I'm not sure if this would work. Also, if we're adding docs, I'd love it if it's added to all of the components instead of just doing this for React. Not sure if there's a way to not duplicate the docs across different files, it would be very nice if it's possible to use a single source for the docs...
@@ -30,6 +32,8 @@ export default function Giscus({ | |||
|
|||
return ( | |||
<giscus-widget | |||
style={style} | |||
className={className} |
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.
Does this work? It's a custom element so I doubt this could just work as-is, since the element doesn't explicitly accept style
and class
attributes.
id?: string; | ||
host?: string; | ||
repo: `${string}/${string}`; | ||
repoid: string; | ||
category?: string; | ||
categoryid?: string; | ||
categoryid: string; |
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 isn't required if the chosen mapping is number
.
@laymonage, I can check this the days, but I don't know so much over Angular and Vue |
I added some TSDocs to the Giscus type definition. I also added
style
andclassName
props for inline styling. Class name is useful for styled componentsFeel free to make/open requests :D