Skip to content

Conversation

DocFX
Copy link
Contributor

@DocFX DocFX commented Nov 3, 2024

Q A
Bug fix? no
New feature? no
License MIT

Stumbled upon the documentation, sweated some time on understanding the multiple layers of magic in the demo, thought this would help some people. :)

@carsonbot carsonbot added the Status: Needs Review Needs to be reviewed label Nov 3, 2024
@smnandre
Copy link
Member

smnandre commented Nov 3, 2024

Hi @DocFX and thank you for this PR.

Would you explain a bit more what you mean by

.products accessor checks at least if a getProducts() method exists

Or more specifically what was not clear at first ?

(Genuinely trying to understand where we can improve documentation -- more globally i mean)

@smnandre smnandre added Documentation Improvements or additions to documentation Status: Waiting feedback Needs feedback from the author LiveComponent and removed Status: Needs Review Needs to be reviewed labels Nov 3, 2024
@smnandre smnandre changed the title Explicit accessor on live component demo [LiveComponent] Explicit accessor on live component demo Nov 3, 2024
@DocFX
Copy link
Contributor Author

DocFX commented Nov 12, 2024

Hi @DocFX and thank you for this PR.

Would you explain a bit more what you mean by

.products accessor checks at least if a getProducts() method exists

Or more specifically what was not clear at first ?

(Genuinely trying to understand where we can improve documentation -- more globally i mean)

Actually, I feel like this part of documentation uses a little bit too much "magic".
The example is really precise and does not really separate what is specific to it from what is generic and provided by the bundle.

I really struggled at first to understand what the relation was between all files. The asbtraction layer between the JS and the objects is already a little hard to deal with. It took some time for me to understand that this uses the automatic getter inspired by twig "dot" accessor.

@smnandre
Copy link
Member

It took some time for me to understand that this uses the automatic getter inspired by twig "dot" accessor.

It is not inspired by the Twig "dot" accessor, it is the Twig dot accessor :)

We have a warning to read the TwigComponent documentation before, but it could be highlighted more i guess.

@smnandre
Copy link
Member

Thank you for bringing this up and sharing your thoughts. I'm closing this for now as there aren’t any immediate actions we can take on our side. The next version of the website will address some of these points, but at the moment, we’re limited in what we can do. LiveComponents can be a bit challenging to grasp initially, especially without prior knowledge of Twig and TwigComponent.

We appreciate your patience and understanding!

@smnandre smnandre closed this Nov 23, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Documentation Improvements or additions to documentation LiveComponent Status: Waiting feedback Needs feedback from the author

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants