Socket
Socket
Sign inDemoInstall

@testing-library/react-hooks

Package Overview
Dependencies
Maintainers
13
Versions
53
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@testing-library/react-hooks - npm Package Compare versions

Comparing version 8.0.0 to 8.0.1

src/__tests__/ssr.test.ts

13

lib/server/pure.js

@@ -84,9 +84,8 @@ "use strict";

renderProps = props;
(0, _testUtils.act)(() => {
try {
serverOutput = ReactDOMServer.renderToString(testHarness(props));
} catch (e) {
rendererProps.setError(e);
}
});
try {
serverOutput = ReactDOMServer.renderToString(testHarness(props));
} catch (e) {
rendererProps.setError(e);
}
},

@@ -93,0 +92,0 @@

{
"name": "@testing-library/react-hooks",
"version": "8.0.0",
"version": "8.0.1",
"description": "Simple and complete React hooks testing utilities that encourage good testing practices.",

@@ -5,0 +5,0 @@ "main": "lib/index.js",

@@ -50,2 +50,3 @@ <div align="center">

Please be patient as we finalise these changes in the respective testing libraries.
In the mean time you can install `@testing-library/react@^13.1`

@@ -201,3 +202,3 @@ ## Table of Contents

<td align="center"><a href="https://gillchristian.xyz"><img src="https://avatars2.githubusercontent.com/u/8309423?v=4?s=100" width="100px;" alt=""/><br /><sub><b>Christian Gill</b></sub></a><br /><a href="https://github.com/testing-library/react-hooks-testing-library/commits?author=gillchristian" title="Documentation">πŸ“–</a></td>
<td align="center"><a href="https://jsjoe.io"><img src="https://avatars3.githubusercontent.com/u/3806031?v=4?s=100" width="100px;" alt=""/><br /><sub><b>JavaScript Joe</b></sub></a><br /><a href="#tutorial-jsjoeio" title="Tutorials">βœ…</a></td>
<td align="center"><a href="https://jsjoe.io"><img src="https://avatars3.githubusercontent.com/u/3806031?v=4?s=100" width="100px;" alt=""/><br /><sub><b>JavaScript Joe</b></sub></a><br /><a href="#tutorial-jsjoeio" title="Tutorials">βœ…</a> <a href="https://github.com/testing-library/react-hooks-testing-library/commits?author=jsjoeio" title="Tests">⚠️</a></td>
</tr>

@@ -204,0 +205,0 @@ <tr>

@@ -16,3 +16,3 @@ import * as ReactDOMServer from 'react-dom/server'

let container: HTMLDivElement | undefined
let serverOutput: string = ''
let serverOutput = ''
const testHarness = createTestHarness(rendererProps, wrapper, false)

@@ -23,9 +23,7 @@

renderProps = props
act(() => {
try {
serverOutput = ReactDOMServer.renderToString(testHarness(props))
} catch (e: unknown) {
rendererProps.setError(e as Error)
}
})
try {
serverOutput = ReactDOMServer.renderToString(testHarness(props))
} catch (e: unknown) {
rendererProps.setError(e as Error)
}
},

@@ -32,0 +30,0 @@ hydrate() {

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚑️ by Socket Inc