mirror of
https://github.com/withastro/astro.git
synced 2025-01-20 22:12:38 -05:00
[ci] format
This commit is contained in:
parent
ccc05d5401
commit
2e58904cd4
1 changed files with 4 additions and 1 deletions
|
@ -13,7 +13,10 @@ export function getMarkdownCodeForImages(imagePaths: MarkdownImagePath[], html:
|
|||
.map((entry) => {
|
||||
const rawUrl = JSON.stringify(entry.raw);
|
||||
return `{
|
||||
const regex = new RegExp('__ASTRO_IMAGE_="([^"]*' + ${rawUrl.replace(/[.*+?^${}()|[\]\\]/g, '\\\\$&')} + '[^"]*)"', 'g');
|
||||
const regex = new RegExp('__ASTRO_IMAGE_="([^"]*' + ${rawUrl.replace(
|
||||
/[.*+?^${}()|[\]\\]/g,
|
||||
'\\\\$&'
|
||||
)} + '[^"]*)"', 'g');
|
||||
let match;
|
||||
let occurrenceCounter = 0;
|
||||
while ((match = regex.exec(html)) !== null) {
|
||||
|
|
Loading…
Add table
Reference in a new issue