0.0.3 • Published 4 months ago

react-component-instance v0.0.3

Weekly downloads
-
License
ISC
Repository
github
Last release
4 months ago

react-component-instance

Get a React class component instance from its DOM element

import getInstance from 'react-component-instance'

With @testing-library/react

Note that for use with Testing Library import from react-component-instance/container

import getInstance from 'react-component-instance/container'

import {
  render
} from '@testing-library/react'

const {
  container
} = render(
  <Component />
)

const instance = getInstance(container)
0.0.3

4 months ago

0.0.2

4 months ago

0.0.1

4 months ago

0.0.0

4 months ago