Remove “(optional)” text from checkout fields in Woocommerce 3.4+
问题 I was previously using this answer to hide checkout fields based on chosen shipping method, it worked fine until an update (3.4.2 current version) I think not sure what has changed but it doesn't work as intended anymore. Previously when local pickup was chosen some fields were hidden and made optional and when delivery was chosen it would show those fields again all via dynamically without reloading the page. Now it shows and hides the fields as required however, when delivery is chosen it