On August 25, U.S. District Court Judge Robert Pitman enjoyed a Texas law that requires anyone who contracts to do any work for any governmental entity in the state to pledge that he or she does not support an economic boycott of Israel. Here is the decision in Amawi v Pflugerville Independent School District, w.d., 1:18cv-1091. The First Amendment protects the right of individuals to speak, and also the right of individuals not to be compelled to speak.
This is not an election law decision, but it is a free speech decision, and the connection between free speech and election law is strong, and ought to be even stronger. Thanks to the Institute for Free Speech for the link.