Skip to content

Conversation

@bwcr
Copy link
Contributor

@bwcr bwcr commented Oct 29, 2025

📝 Description

Added a mock implementation for matchMedia to the testing documentation. matchmedia is needed to make the unit test work.

⛳️ Current behavior (updates)

I am currently modifying the testing documentation to support unit tests with testing-library and jsdom

🚀 New behavior

Based on the tutorial, it somehow returns TypeError: window.matchMedia is not a function, so I decided to add matchmedia function to the setup test file

Added a mock implementation for matchMedia to the testing documentation.
@changeset-bot
Copy link

changeset-bot bot commented Oct 29, 2025

⚠️ No Changeset found

Latest commit: 4f3316a

Merging this PR will not cause a version bump for any packages. If these changes should not result in a new version, you're good to go. If these changes should result in a version bump, you need to add a changeset.

This PR includes no changesets

When changesets are added to this PR, you'll see the packages that this PR includes changesets for and the associated semver types

Click here to learn what changesets are, and how to add one.

Click here if you're a maintainer who wants to add a changeset to this PR

@vercel
Copy link

vercel bot commented Oct 29, 2025

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Preview Updated (UTC)
chakra-ui-storybook Ready Ready Preview Oct 29, 2025 4:34am
chakra-v3-docs Ready Ready Preview Oct 29, 2025 4:34am

@segunadebayo segunadebayo merged commit 10163e4 into chakra-ui:main Oct 29, 2025
2 checks passed
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