File size: 271 Bytes
7f5ba59
 
 
 
 
 
 
1
2
3
4
5
6
7
export function parseTemplate(template, variables) {
  if (!template) return '';
  return template
    .replace(/{username}/g, variables.username ?? '')
    .replace(/{server}/g, variables.server ?? '')
    .replace(/{memberCount}/g, variables.memberCount ?? '');
}