I would like to target a button that contains the name ="loginButton", and click the element after loading etc so it doesnt click on the loading spinner. How do I go about this webdriverwait targetting the name element?
from selenium.webdriver.support.wait import WebDriverWait
from selenium.webdriver.common.by import By
from selenium.webdriver.support import expected_conditions as EC
WebDriverWait(driver, 20).until(EC.element_to_be_clickable((find_element_by_name('loginButton'), "loginButton"))).click()