Previously, the most common method for "removing" text from elements was through text-indent: -9999px
, however, it is now recommended to use
text-indent: 100%;
white-space: nowrap;
overflow: hidden;
This way, the browser does not need to create a huge 9999px box. But why not simply utilize font-size: 0
? What are the downsides of employing this approach?