News for hackers. Stuff that matters.
Re:Next.js 13 by latchkey on Tuesday October 25, 2022 @03:09PM (#33334852)
NextJS could just create alt="" when rendering the HTML <img> element from their <Image> element.
Re:Next.js 13 by MaxLeiter on Tuesday October 25, 2022 @03:57PM (#33335371)
That could harm the experience for assistive tech users more than no alt tag
Re:Next.js 13 by dariusj18 on Tuesday October 25, 2022 @06:04PM (#33336746)
I think the compromise would be an optional build parameter that allows this functionality.
Re:Next.js 13 by Serenacula on Tuesday October 25, 2022 @09:33PM (#33338620)
Frameworks shouldn't be changing the content you coded on the sly, that's just asking for trouble. Imagine trying to debug that.
Re:Next.js 13 by Vinnl on Wednesday October 26, 2022 @02:49AM (#33340571)
Next.js can't determine what the value of the alt tag should be, i.e. whether it should actually be empty. If it would do this, it would actually tell screen reader users that the image is decorative, instead of warning them that there might be information conveyed in the image that the developer forgot to label.