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

tech-story: [M3-9483] - Add rule to prevent direct imports of Link from react-router-dom #11801

Open
wants to merge 8 commits into
base: develop
Choose a base branch
from

Conversation

coliu-akamai
Copy link
Contributor

@coliu-akamai coliu-akamai commented Mar 6, 2025

Description 📝

  • Added a rule to restrict imports to Link from react-router-dom
  • Updated imports for Links to be from src/components/Link + added aria labels, or disabled the rule for files that still needed react-router-dom's Link

How to test 🧪

Verification steps

  • For files with updated imports to src/components/Link, confirm that Links still work as expected
Author Checklists

As an Author, to speed up the review process, I considered 🤔

👀 Doing a self review
❔ Our contribution guidelines
🤏 Splitting feature into small PRs
➕ Adding a changeset
🧪 Providing/improving test coverage
🔐 Removing all sensitive information from the code and PR description
🚩 Using a feature flag to protect the release
👣 Providing comprehensive reproduction steps
📑 Providing or updating our documentation
🕛 Scheduling a pair reviewing session
📱 Providing mobile support
♿ Providing accessibility support


  • I have read and considered all applicable items listed above.

As an Author, before moving this PR from Draft to Open, I confirmed ✅

  • All unit tests are passing
  • TypeScript compilation succeeded without errors
  • Code passes all linting rules

@coliu-akamai coliu-akamai self-assigned this Mar 6, 2025
@coliu-akamai coliu-akamai changed the title tech-stories: Add rule to prevent direct imports of Link from react-router-dom tech-story: [M3-9483] - Add rule to prevent direct imports of Link from react-router-dom Mar 7, 2025
@coliu-akamai coliu-akamai force-pushed the add-restricted-imports branch from b367fa5 to fecf4c2 Compare March 7, 2025 22:24
@coliu-akamai coliu-akamai marked this pull request as ready for review March 7, 2025 22:51
@coliu-akamai coliu-akamai requested a review from a team as a code owner March 7, 2025 22:51
@coliu-akamai coliu-akamai requested review from mjac0bs and bnussman-akamai and removed request for a team March 7, 2025 22:51
@coliu-akamai coliu-akamai added Add'tl Approval Needed Waiting on another approval! and removed Ready for Review labels Mar 11, 2025
Copy link

github-actions bot commented Mar 11, 2025

Coverage Report:
Base Coverage: 80.08%
Current Coverage: 80.07%

Copy link
Contributor

@mjac0bs mjac0bs left a comment

Choose a reason for hiding this comment

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

Thanks for the follow up, Connie!

@mjac0bs mjac0bs added Approved Multiple approvals and ready to merge! and removed Add'tl Approval Needed Waiting on another approval! labels Mar 11, 2025
@linode-gh-bot
Copy link
Collaborator

Cloud Manager UI test results

🔺 4 failing tests on test run #8 ↗︎

❌ Failing✅ Passing↪️ Skipped🕐 Duration
4 Failing532 Passing3 Skipped130m 34s

Details

Failing Tests
SpecTest
smoke-linode-landing-table.spec.tslinode landing checks » checks the landing top menu items
linode-config.spec.tsEnd-to-End » Clones a config
edit-user-alert.spec.tsIntegration Tests for Edit Alert » should correctly display the details of the alert in the Edit Alert page
object-storage.e2e.spec.tsobject storage end-to-end tests » can create and delete object storage buckets

Troubleshooting

Use this command to re-run the failing tests:

pnpm cy:run -s "cypress/e2e/core/linodes/smoke-linode-landing-table.spec.ts,cypress/e2e/core/linodes/linode-config.spec.ts,cypress/e2e/core/cloudpulse/edit-user-alert.spec.ts,cypress/e2e/core/objectStorage/object-storage.e2e.spec.ts"

@coliu-akamai
Copy link
Contributor Author

smoke-landing and object-storage have been consistently failing 🤔 gonna look into them

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Approved Multiple approvals and ready to merge!
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants