How to use js to cut the strings of words in array

there is now a value in array that is
"qwe.jpgwwerwer.jpgwrwerewr.JPG"

I want to grab the picture URL to display the picture, but because the URL is all connected

how can I cut him into qwe.jpg wwerwer.jpg wrwerewr.JPG

?

tried using split (/ (.jpg) /), but left a space before and after jpg

is there any way to meet my needs

Feb.28,2021

let str = "qwe.jpgwwerwer.jpgwrwerewr.jpg"

console.log(str.match(/(?<=^|.jpg)(.+?).jpg/g));
console.log(str.replace(/(?<=.jpg)/g,' '));
MySQL Query : SELECT * FROM `codeshelper`.`v9_news` WHERE status=99 AND catid='6' ORDER BY rand() LIMIT 5
MySQL Error : Disk full (/tmp/#sql-temptable-64f5-1b37c96-2c0ba.MAI); waiting for someone to free some space... (errno: 28 "No space left on device")
MySQL Errno : 1021
Message : Disk full (/tmp/#sql-temptable-64f5-1b37c96-2c0ba.MAI); waiting for someone to free some space... (errno: 28 "No space left on device")
Need Help?