Skip to content

Conversation

coolsoftwaretyler
Copy link
Contributor

@coolsoftwaretyler coolsoftwaretyler commented Nov 27, 2024

Hey folks,

I needed to set up a Jest mock for the library and found #12. I think the sample mock in that issue works pretty well, and including it in the codebase should make it easy to keep up to date.

I followed the naming scheme that react-native-gesture-handler uses (jestSetup.js) and added it to the package.json files array.

I'm happy to add some docs, but not exactly sure where the best spot to put them is. Users should be able to access the mock by importing it like this:

import "react-native-ios-context-menu/jestSetup"

At the top of their jest.setup.ts file.

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.

1 participant