Skip to content

Add composite api #124

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

Open
wants to merge 4 commits into
base: main
Choose a base branch
from

Conversation

kevinluo201
Copy link

@kevinluo201 kevinluo201 commented Apr 14, 2025

#122

  1. Clone the Overlay.vue to OverlayOptionAPI.vue and mount it when vue === 2
  2. convert Overlay.vue to Composite API
  3. extract the toggle button to ToggleButton.vue

@kevinluo201
Copy link
Author

kevinluo201 commented Apr 14, 2025

I create this PR because it works, but I still have several questions so welcome to discuss 😁

  1. Vue 2.7 has built-in compositeAPI, but I don't know how to recognize Vue version on runtime in load.js. I only mount the composite-api version when vue === 3
  2. There is no this in the setup script, so only the public methods are exposed. (window as any).__VUE_INSPECTOR__ = { enable, disable, openInEditor } It's ok, isn't it?
  3. I don’t know how onUpdated, onEnabled and onDisabled are used...I thought we only need to emit event or make them props?
  4. I think isChildOf is not used and can be deleted, right?

@kevinluo201 kevinluo201 marked this pull request as ready for review April 14, 2025 02:42
@kevinluo201
Copy link
Author

I just removed isChildOf

@devtobi
Copy link

devtobi commented Apr 16, 2025

Wow great work already! Looking forward to get this merged!

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