Skip to content

Commit

Permalink
fix(react): use fragment for inner child elements
Browse files Browse the repository at this point in the history
  • Loading branch information
hirsch88 committed Mar 1, 2022
1 parent b5f554b commit 86d4986
Show file tree
Hide file tree
Showing 3 changed files with 27 additions and 27 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -89,9 +89,9 @@ export const createReactComponent = <
* React.createElement causes all elements to be rendered
* as <tagname> instead of the actual Web Component.
*/
const component = createElement(tagName, newProps, children)
const fragment = createElement(Fragment, {}, component)
return fragment
const fragment = createElement(Fragment, {}, children)
const component = createElement(tagName, newProps, fragment)
return component
}

static get displayName() {
Expand Down
46 changes: 23 additions & 23 deletions packages/components/package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion packages/components/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -90,7 +90,7 @@
"devDependencies": {
"@babel/core": "^7.16.0",
"@baloise/angular-output-target": "^1.2.0",
"@baloise/react-output-target": "^0.4.0",
"@baloise/react-output-target": "^0.4.1",
"@baloise/vue-output-target": "^0.7.3",
"@etchteam/storybook-addon-status": "^4.2.0",
"@stencil/postcss": "^2.1.0",
Expand Down

0 comments on commit 86d4986

Please sign in to comment.