0.1.29 • Published 11 months ago

react-native-contains v0.1.29

Weekly downloads
-
License
MIT
Repository
github
Last release
11 months ago

react-native-contains

Universal element contains for react, react-native, and react-native web

Example 1

import { useRef } from "react",
import { View } from "react-native",
import contains from "react-native-contains";

function Component() {
  const ref = useRef();
  return (
    <View>
      <View ref={ref}>
        <View onPress={((event) => {
          contains(ref.current, event.target); // true
        })}/>
      </View>
      <View onPress={((event) => {
        contains(ref.current, event.target); // false
      })}/>
    </View>
  )
}

Documentation

API Docs

0.1.13

1 year ago

0.1.14

1 year ago

0.1.15

1 year ago

0.1.27

12 months ago

0.1.29

11 months ago

0.1.20

1 year ago

0.1.21

1 year ago

0.1.22

12 months ago

0.1.23

12 months ago

0.1.24

12 months ago

0.1.25

12 months ago

0.1.26

12 months ago

0.1.16

1 year ago

0.1.17

1 year ago

0.1.18

1 year ago

0.1.19

1 year ago

0.1.11

4 years ago

0.1.10

4 years ago

0.1.9

4 years ago

0.1.8

4 years ago

0.1.7

4 years ago

0.1.6

4 years ago

0.1.5

4 years ago

0.1.4

4 years ago

0.1.3

4 years ago

0.1.2

4 years ago

0.1.1

4 years ago

0.1.0

4 years ago