Adding just a small amount of polymers to a liquid can drastically change its behavior. The polymers make the liquid viscoelastic, meaning that, under deformation, the liquid shows behaviors that are both viscous (like all fluids) and elastic (i.e. able to resume its original shape, like a rubber band). These properties are particularly identifiable under extensional loading, like in the animation above. Under these loads, the polymers in the fluid stretch and rearrange, creating an internal compressive stress that acts opposite the imposed tensile stress. It’s this balance of forces, along with ever-present surface tension that creates the beads-on-a-string effect seen above. (Image credit: B. Keshavarz)
ETA: As usual, Tumblr gave me issues with an animated GIF. It should be fixed now. Sorry!