Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix and update docs #25

Merged
merged 3 commits into from
May 21, 2023
Merged

Fix and update docs #25

merged 3 commits into from
May 21, 2023

Conversation

choowx
Copy link
Contributor

@choowx choowx commented May 20, 2023

This PR makes 3 changes to the code examples in the docs.

  1. Fix incorrect parameters used in addIf method.
    Corrects the 2nd and 3rd arguments to be title and url respectively. Additionally, it ensures that the configure callback is placed as the 4th parameter, and the callback now receives a Section instance instead of a Navigation instance.

  2. Populate missing attributes and depth to the array outputs.

  3. Simplified the usage by utilizing arrow functions in the callbacks.

Feel free to share your thoughts and review.😄

@freekmurze freekmurze merged commit 31e2e32 into spatie:main May 21, 2023
@freekmurze
Copy link
Member

Thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants