Skip to content

Commit

Permalink
fix(extract-component): fixed component generation that includes inst…
Browse files Browse the repository at this point in the history
…ance references
  • Loading branch information
Boris Litvinsky committed Aug 4, 2018
1 parent 5f5f157 commit d6b240b
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/modules/component-builder.ts
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ function buildStatefulComponent(name, code, attributes) {

export function buildComponent(name, code, attributes) {

if (attributes.memberProps.size) {
if (attributes.memberProps.size || attributes.state.size) {
return buildStatefulComponent(name, code, attributes);
} else {
return buildFunctionalComponent(name, code, attributes.argumentProps);
Expand Down

0 comments on commit d6b240b

Please sign in to comment.