Skip to content

Commit

Permalink
fix: fixed marko 3 components without widgets
Browse files Browse the repository at this point in the history
  • Loading branch information
oxala committed Sep 28, 2018
1 parent b1f1185 commit c755035
Show file tree
Hide file tree
Showing 5 changed files with 7 additions and 7 deletions.
4 changes: 1 addition & 3 deletions src/render.js
Original file line number Diff line number Diff line change
Expand Up @@ -11,9 +11,7 @@ const getWidgetInstance = (renderer, input) => {
};
}

const mountWidget = comp => mount(comp).getWidget();

return mountWidget(renderer.renderSync(clone(input)));
return mount(renderer.renderSync(clone(input))).getWidget();
};
const getComponentInstance = (renderer, input, withAwait) => {
const mountComponent = comp => mount(comp).getComponent();
Expand Down
3 changes: 2 additions & 1 deletion tests/marko3/components/tbody-component/index.marko
Original file line number Diff line number Diff line change
@@ -1,7 +1,8 @@
<tbody>
<tr>
<td>
tbody-component<lasso-img src="."/>
tbody-component
<lasso-img src="."/>
</td>
</tr>
</tbody>
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ Array [
<tbody>
<tr>
<td>
tbody-component
tbody-component
<lasso-img
src="."
/>
Expand Down
3 changes: 2 additions & 1 deletion tests/marko4/components/tbody-component/index.marko
Original file line number Diff line number Diff line change
@@ -1,7 +1,8 @@
<tbody>
<tr>
<td>
tbody-component<lasso-img src="."/>
tbody-component
<lasso-img src="."/>
</td>
</tr>
</tbody>
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ Array [
<tbody>
<tr>
<td>
tbody-component
tbody-component
<lasso-img
src="."
/>
Expand Down

0 comments on commit c755035

Please sign in to comment.