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

docs: add documentation for <Motion> component #192

Merged
merged 3 commits into from
May 29, 2024

Conversation

BobbieGoede
Copy link
Member

πŸ”— Linked issue

❓ Type of change

  • πŸ“– Documentation (updates to the documentation, readme or JSDoc annotations)
  • 🐞 Bug fix (a non-breaking change that fixes an issue)
  • πŸ‘Œ Enhancement (improving an existing functionality like performance)
  • ✨ New feature (a non-breaking change that adds functionality)
  • 🧹 Chore (updates to the build process or auxiliary tools and libraries)
  • ⚠️ Breaking change (fix or feature that would cause existing functionality to change)

πŸ“š Description

Adds a very basic page to document the <Motion> component, this is essentially a modified version of the "Directive Usage" page. I'm not exactly good at writing documentation so feel free to add more details if necessary. I left out documentation for the :instance prop on purpose as this doesn't seem to do anything, this is something to look into later.

@Tahul
If this documentation is sufficient (for now), I think we should publish a new release πŸ˜„

πŸ“ Checklist

  • I have linked an issue or discussion.
  • I have added tests (if possible).
  • I have updated the documentation accordingly.

@BobbieGoede BobbieGoede added the documentation Improvements or additions to documentation label May 27, 2024
@BobbieGoede BobbieGoede requested review from Tahul and cpreston321 May 27, 2024 16:47
@Tahul
Copy link
Member

Tahul commented May 28, 2024

looks great ; what would you think of adding an example for that component, showcasing its features?

@BobbieGoede
Copy link
Member Author

I added an example for the <Motion> and <MotionGroup> components, the functionality is mostly the same as the v-motion directive except the components should work better for SSR, not sure how we would showcase this πŸ˜….

On a separate note, maybe a future improvement to <MotionGroup> could be to allow passing a separate delay or duration prop that accepts a function, this would make it possible to easily create staggered animations.

For now I'm mostly curious if people will use the components over the directive, the docs will probably need further reworks to guide users in that direction.

@BobbieGoede
Copy link
Member Author

I have opened a draft PR #193 that demonstrates one way we could improve the <MotionGroup> component.

That will be something to explore a bit later, I prefer publishing a release first before adding new features for the sake of stability πŸ˜…

@Tahul Tahul merged commit d237079 into vueuse:main May 29, 2024
5 checks passed
@Tahul
Copy link
Member

Tahul commented May 29, 2024

For now I'm mostly curious if people will use the components over the directive, the docs will probably need further reworks to guide users in that direction.

Same, let's see :)

Excellent work, thanks a lot @BobbieGoede!

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
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants