const regex = /(?<=:|^)(?!.*:)(?=.*([Ee]ur|EUR)).*/gm;
// Alternative syntax using RegExp constructor
// const regex = new RegExp('(?<=:|^)(?!.*:)(?=.*([Ee]ur|EUR)).*', 'gm')
const str = `[
"ERDF : EUR 2.7 million",
"ERDF : EUR 961 000",
"ERDF: 7 305 000 DKR (+/- EUR 974 000) ",
FEOGA: 40 826 EUR",
"49 % of eligible costs",
"ERDF contribution: 64%",
"FEDER (Objectif 5b 1994-1996) 60 979 euros (400 000 FRF)",
"FEDER, Objectif 2, 1994 - 1999: 1 116 000 EUR",
"EUR 8.000.000",
"EUR 7.200.000",
"EUR 4.200.000",
"EUR 0.2 million",
"EUR 0.6 million",
"FEDER: 830 842 euros (5 450 000 FRF)",
"EUR 7,220,000,000",
"DKR 1 220 000 + DKR 1 380 000 ",
"GBP 150 000"
]`;
const subst = ``;
// The substituted value will be contained in the result variable
const result = str.replace(regex, subst);
console.log('Substitution result: ', result);
Please keep in mind that these code samples are automatically generated and are not guaranteed to work. If you find any syntax errors, feel free to submit a bug report. For a full regex reference for JavaScript, please visit: https://developer.mozilla.org/en/docs/Web/JavaScript/Guide/Regular_Expressions