React testing library setting window=undefined

前端 未结 0 314
挽巷
挽巷 2021-01-15 17:23

I am testing a react hook which gets the window-dimensions from window.innerheight and window.innerwidth. It uses the following code to handle server side rendering:

相关标签:
回答
  • 消灭零回复
提交回复
热议问题