In myth and folklore (and settings derived from them), there isn't always consistency:
- Dwarfs: the dwarf Alviss is turned to stone in sunlight in the Poetic Edda (which inspired Gandalf's dispatch of the trolls in The Hobbit). But some other dwarfs in the Edda don't seem to be affected thus.
- Vampires - but this, I think, comes from the 1922 film Nosferatu; in Dracula, the film's inspiration, the eponymous vampire walks around in daylight.
- Trolls - in Scandinavian folklore and in Tolkien's works - with Sauron's Olog-hai being an exception to the normal rule.
In general, traditional monsters tend to be averse to sunlight rather than being destroyed by it. This is probably a reflection of nocturnal predatory animals (wolves, hyenas, etc); they
might be out in the daylight, but they're definitely more active dangerous after dark.
Lovecraft's Haunter of the Dark is extremely vulnerable to light.