Skip to content

Fix DecryptedText imports to resolve Vite TypeScript build failure#855

Merged
DavidHDev merged 1 commit intoDavidHDev:mainfrom
shrkawy:fix/decryptedtext-imports
Jan 20, 2026
Merged

Fix DecryptedText imports to resolve Vite TypeScript build failure#855
DavidHDev merged 1 commit intoDavidHDev:mainfrom
shrkawy:fix/decryptedtext-imports

Conversation

@shrkawy
Copy link
Copy Markdown
Contributor

@shrkawy shrkawy commented Jan 20, 2026

Summary

This PR fixes a Vite + TypeScript build failure caused by incorrect and unused imports in the DecryptedText component.
Fixes #853

What Changed

  • Removed the unused ReactNode import from react
  • Split motion/react imports to correctly separate:
    • HTMLMotionProps as a type-only import
    • motion as a runtime import
  • Streamlined imports to align with Vite and TypeScript best practices

Why This Change

The previous import structure caused TypeScript build errors in Vite due to:

  • Unused ReactNode import
  • Mixing type and runtime imports from motion/react

This update ensures clean builds and proper type handling.

Testing

  • ✅ Tested locally with Vite
  • ✅ Verified successful TypeScript build
  • ✅ Checked browser console — no errors
  • ✅ No visual or behavioral changes to the component on desktop or mobile

Screenshots / Videos

Not applicable — this change does not affect UI or component behavior.

Copy link
Copy Markdown
Owner

@DavidHDev DavidHDev left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nice!

@DavidHDev DavidHDev merged commit 47c1080 into DavidHDev:main Jan 20, 2026
@shrkawy shrkawy deleted the fix/decryptedtext-imports branch January 20, 2026 20:58
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.

[BUG]: text-animations/decrypted-text, need type keyword

2 participants