Skip to content

Conversation

@felipmartins
Copy link
Contributor

@felipmartins felipmartins commented Dec 5, 2023

Greetings @adamghill !

I was following documentation and noticed that creating multiple components for the first time in an app results in an undesired loop (print below)

Captura de Tela 2023-12-05 às 19 37 30

The changes I'm proposing fix that by checking the number of files in components folder. (print below)

Captura de Tela 2023-12-05 às 19 34 47

Let me know if you need anything!

@adamghill
Copy link
Owner

Hey, sorry I missed this -- thanks for the PR! This looks like it would fix the problem, but would it be cleaner to set is_first_component to False on line 196?

@felipmartins
Copy link
Contributor Author

You are absolutely right, @adamghill . I made the change following your suggestion, much cleaner!

But anyway, someday it might make sense to extract some logic from this loop. I mean, does not please me the idea of having such an extensive loop containing all logic.

Makes sense?

@adamghill
Copy link
Owner

someday it might make sense to extract some logic from this loop

Yep, makes sense to me! I'd merge a PR if you want to extract that logic.

@felipmartins
Copy link
Contributor Author

@adamghill, sorry for taking so long to reply this.

You can close this PR, I've just sent another one

@adamghill
Copy link
Owner

No worries, I know how it is! 😆

@adamghill adamghill closed this Jan 6, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

2 participants