preact-render-to-string
preact-render-to-string copied to clipboard
:page_facing_up: Universal rendering for Preact: render JSX and Preact components to HTML.
Not sure if this an issue or a clarification. If I have some SVG, such as `` It doesn't work correctly. If I change 'strokeWidth' to 'stroke-width' (changed to lower...
Mixing both default and named exports has no clearly defined behaviour and can easily lead to unexpected results. Some tools use a combination of `default` + `__esModule` property and others...
Note: I've left this as `src/ropes.js` for now, since it doesn't include all the pretty-printing from `src/index.js`. We need to remove that from the main package anyway. | Before |...
Add an option to preserve whitespace/indentation for certain elements. Defaults to `['pre']` **Caution** I'm not 100% sure this doesn't break pretty printing, tests seem fine though. Fixes #143
This PR aims to introduce `renderToNodeStream`. `renderToNodeStream` is especially useful when used together with `Suspense`. This will allow SSR to send HTML to the client as soon as possible. TODO:...
Taken the list of [Preact supported attributes](https://github.com/developit/preact/blob/f717ee8e53248d75ff8c1a46966adeec295d339b/src/preact.d.ts#L547) and transform these attributes when building the rendered string.
I found this issue whilst comparing snapshots made with jest with and without coverage. When --coverage adds the istanbul babel plugin it adds random elements to the output. I made...
This introduces two workflows. Open for feedback and improvements. **push.yml** A regular CI build that runs tests. Todo - [ ] Test coverage **release-publish.yml** Triggers when a release is published...
When setting `{pretty: true}` in options, looks like any `` tags in the output get extra indentation added (based on the nesting level of the tag), breaking its contents.