react check if window exists

Solutions on MaxInterview for react check if window exists by the best coders in the world

showing results for - "react check if window exists"
Julia
20 Sep 2016
1import os
2
3os.path.exists("file.txt") # Or folder, will return true or false
Juliana
18 Oct 2020
1if (typeof yourFunctionName == 'function') { 
2  yourFunctionName(); 
3}
Simeon
26 Aug 2020
1if (typeof window !== 'undefined') {
2    let paypal = require('paypal-checkout');
3}
similar questions
queries leading to this page
react check if window exists