generated from autonomic-cooperative/astro-payload-template
Add alt attribute to imgs
This commit is contained in:
@ -12,12 +12,13 @@ export const getContentArray = (content: any) => {
|
||||
src: node.value.filename,
|
||||
width: `${node.value.width}`,
|
||||
height: `${node.value.height}`,
|
||||
alt: `${node.value.alt}`,
|
||||
}),
|
||||
},
|
||||
}).replaceAll("<p></p>", "<p> </p>");
|
||||
const htmlImageArray: (
|
||||
| string
|
||||
| { src: string; width: number; height: number }
|
||||
| { src: string; width: number; height: number, alt: string }
|
||||
)[] = [];
|
||||
let lastIndex = 0;
|
||||
while (true) {
|
||||
|
Reference in New Issue
Block a user