polymorph:
The IO pins do have internal pullups, as you say just use INPUT_PULLUP when setting up the input. Then the input won't float when the switch is open.However, with long wires or an electrically noisy environment, a lower resistance pullup resistor added externally can help make it more resistant to picking up noise when the switch is open.
Ah, I see. My error was I was looking at a pinout of the Wemos D1 where only the D3 and D4 pins have a 10K Pull-Up and assuming that the Arduino was similar, in that only certain pins have built-in pullups.
https://wiki.wemos.cc/products:d1:d1_mini
So in the case of the Arduino, every IO pin has a built-in pullup and can utilize INPUT_PULLUP in pinmode. The Wemos, however, does not and only D3 and D4 are capable of this.