-
-
Notifications
You must be signed in to change notification settings - Fork 3
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
feat: add htmlWithOptions
#22
base: main
Are you sure you want to change the base?
Conversation
🦋 Changeset detectedLatest commit: 310ebcc The changes in this PR will be included in the next version bump. This PR includes changesets to release 1 package
Not sure what this means? Click here to learn what changesets are. Click here if you're a maintainer who wants to add another changeset to this PR |
if (options?.tailwind) { | ||
tw(doc); | ||
} |
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.
I've only changed this part, otherwise it's just returning the same function as before.
@@ -8,13 +8,15 @@ Generate a [satori](https://github.com/vercel/satori)-friendly VDOM from a strin | |||
|
|||
Unfortunately, it is built on top of React's JSX and [expects "React-elements-like objects"](https://github.com/vercel/satori#use-without-jsx). This library (`satori-html`) bridges that gap, generating the necessary VDOM object from a string of HTML. | |||
|
|||
> **Note** | |||
> [!NOTE] |
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.
Updated to the new syntax.
@natemoo-re any chance you could have a look at this? Thanks 🙏 |
I would like to have an option to disable tailwind because when not used it might clash with other class names, see KiwiKilian/eleventy-plugin-og-image#216.
Therefore I've implemented
htmlWithOptions
, which could be extended if there shall be more configuration options. I hope it can find a place in the projects scope, otherwise I'm open to any suggestions.