blob: 4d3ed338e93b46d06a9386a572e0e4124868ab48 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
|
let options = {
title: document.title,
prefix: ''
};
export default {
get title () {
return options.title;
},
set title (title) {
options.title = title;
this.displayTitle();
},
get title_prefix () {
return options.prefix;
},
set title_prefix (prefix) {
options.prefix = prefix;
this.displayTitle();
},
displayTitle () {
document.title = `${options.prefix}${options.title}`;
}
};
|