This also receives the element as an argument.