shadow icon indicating copy to clipboard operation
shadow copied to clipboard

Refactor ShadowRoot Component and Improve Type Safety

Open Eg0r0k opened this issue 1 year ago • 3 comments

This pull request refactors the ShadowRoot component to improve code clarity, enhance type safety, and ensure better consistency with Vue best practices. Key changes include:

  • Improved type definitions for better type safety.
  • Refactoring logic for attaching the shadow root to ensure it works more reliably.
  • General cleanup of redundant code and error handling improvements.
  • These updates aim to make the component more maintainable and improve its usage within Vue projects.

Eg0r0k avatar Dec 01 '24 14:12 Eg0r0k

Please format it using prettier, rules in .prettierrc.yaml

2A5F avatar Dec 01 '24 17:12 2A5F

  • Improved typing: Introduces AdoptableShadowRoot and ShadowRootComponent for type safety.
  • Renamed variables: teleportEl, teleportTarget, exposeData, and childPart renamed to snake_case for consistency.
  • Minor cleanup: Removed unused commented-out code.

Eg0r0k avatar Dec 03 '24 19:12 Eg0r0k

Please do not format files other than source code, as this will result in too many diffs. I suggest opening a new branch to extract modifications separately to avoid unnecessary changes.

2A5F avatar Dec 04 '24 06:12 2A5F