Skip to content

fix(components): LinkToExternal #2832

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

Closed
wants to merge 2 commits into from
Closed

fix(components): LinkToExternal #2832

wants to merge 2 commits into from

Conversation

aklkv
Copy link
Collaborator

@aklkv aklkv commented Apr 19, 2025

📌 Summary

Today we are referencing <LinkToExternal/> component and in the many cases it doesn't exists unless consumer has ember-engines as dependancy. In the embroider/vite world all components are evaluated at the build time and needs to resolve correct dependancy. If we were to run hds embroider/vite today it would result in an error about unresolved LinkToExternal component. In order to make this behaviour more controlled we are encapsulating requirements for ember-engines to be explicitly required only in situation when we pass @isRouteExternal as true in which case we do our check for required dependancy resigne component instance or through an error.

Shipping ember-engines is not an option for a couple of reasons:

  • it has very interesting v1 era requirements which are impossible to satisfy in addon structure (nor should we)
  • it is consumer land dependancy and we should leverage this tacktics of not locking users to our version and letting consumer provide own copy only in situation when it's needed. I can see other optimizations in similar fashion but this is the most pressing one at the moment

🛠️ Detailed description

📸 Screenshots

🔗 External links

Jira ticket: HDS-XXX
Figma file: [if it applies]


👀 Component checklist

💬 Please consider using conventional comments when reviewing this PR.

@aklkv aklkv self-assigned this Apr 19, 2025
@aklkv aklkv requested a review from a team as a code owner April 19, 2025 07:56
Copy link

vercel bot commented Apr 19, 2025

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Updated (UTC)
hds-showcase ✅ Ready (Inspect) Visit Preview Apr 22, 2025 7:22am
hds-website ✅ Ready (Inspect) Visit Preview Apr 22, 2025 7:22am

fix(components): `LinkToExtrnal`
@aklkv aklkv force-pushed the fix/link-to-external branch from 3f1be72 to 8bab8ed Compare April 22, 2025 07:18
@aklkv aklkv added the release-candidate Publishes release candidates to npm label Apr 22, 2025
Copy link
Contributor

📦 RC Packages Published

Latest commit: 8bab8ed

Published 1 packages

@hashicorp/design-system-components@4.19.0-rc-20250422072018

yarn up -C @hashicorp/design-system-components@rc

@aklkv
Copy link
Collaborator Author

aklkv commented Apr 22, 2025

superseded by #2838

@aklkv aklkv closed this Apr 22, 2025
@aklkv aklkv deleted the fix/link-to-external branch April 22, 2025 22:46
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
packages/components release-candidate Publishes release candidates to npm
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants