Input Optical Isolation -- Yes I'm a little new..

Either way, thu uC input is high until you close the swithch.
There is only tens of mA going thru the LED, static discharge won't be an issue.