add prettier and format all

This commit is contained in:
Thomas Ruoff
2021-02-08 22:51:35 +01:00
parent d7044f5f78
commit 78af180567
24 changed files with 266 additions and 297 deletions

View File

@@ -1,30 +1,29 @@
function convertLineBreaks(string) {
return string.replace(/\n/g, '\\\\');
};
return string.replace(/\n/g, '\\\\')
}
export function brief(options) {
const {
template = 'brief-fam',
subject = '',
yourRef = '',
yourRefName = 'Ihr Zeichen',
yourMail = '',
myRef = '',
customer = '',
invoice = '',
date = '\\today',
signature = '',
specialMail = '',
address = 'Max Mustermann\\\\Musterstrasse\\\\12345 Musterstadt',
opening = 'Sehr geehrte Damen und Herren',
body = '',
closing = 'Mit freundlichen Grüßen',
ps = '',
enclosing = '',
} = options
const {
template = 'brief-fam',
subject = '',
yourRef = '',
yourRefName = 'Ihr Zeichen',
yourMail = '',
myRef = '',
customer = '',
invoice = '',
date = '\\today',
signature = '',
specialMail = '',
address = 'Max Mustermann\\\\Musterstrasse\\\\12345 Musterstadt',
opening = 'Sehr geehrte Damen und Herren',
body = '',
closing = 'Mit freundlichen Grüßen',
ps = '',
enclosing = '',
} = options;
return `% brief document
return `% brief document
\\documentclass{scrlttr2}
\\LoadLetterOption{${template}}
@@ -56,5 +55,5 @@ export function brief(options) {
%\\encl{${enclosing}}
\\end{letter}
\\end{document}`;
};
\\end{document}`
}