this i have heard from numerous websites, though if you have a very expensive keyboard like mine with built in macro software and other numerous features or a touch pad etc i wouldn't be to quick to slap it in the dish washer on a cool run. when my keyboard kets dirty i usually turn it upside down proceeded by lots of shaking, but that only removes dust. about once per year i just dismantle the whole thing screws on the back and all and clean the whole lot with the alcohol wipes usually you can get to the keyboard key mechanics without any problems and give them a good wipe if any have become sticky. if you keyboard does not have access to the button you can usually prize off the keys of that sort of board and clean them individually, fortunately the design of keyboard is as such that cleaning them no matter how messy can be done with little fuss and a screwdriver.
keep you screws you take out in a bowl so they don't run away, remember what order you took it to pieces (you can take photos) and then reverse the process to put it back together after cleaning. they are very hard to break. under the keys there is sometimes a white protective film on top of a rubber sleve that is always present this is on top of a white film that has the contacts that leads to a very small circuit board where you plug it into the computer.
washing electronics in water is fine. the idea behind this is that electronics only stop working when the contacts on the components break. this happens when people get electronics wet then put them someplace warm then the electronic board begins to expand under the heat, usually unevenly, this causes various components to break away from the electronic board.
so you can wet the hell out of a mother board or a phone or anything providing you do not change the temperature, no components will move, the item drys out. then you may plug it in though some electronics may take several months to dry out such a phones and you must make sure they remain at 20 degrees the whole time. if you plug it in before it drys it will short and not come on until its dry. having said all this its not great to grab a board and flush it with water unless it is your last resort because although in theory it is fine it can still warp and change things which is not so great.