blob: 32e8cf53d6c83237296cb072aae8a8492ff18037 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
|
class Index {
constructor() {}
Init() {this.#EventListener()}
#EventListener() {
const about = document.getElementById('index-about')
const readBlogs = document.getElementsByClassName('index-readblogs')
const websites = {
helpinghands: document.getElementById('helpinghands'),
goodhandhauling: document.getElementById('goodhandhauling')
}
for (let i = 0; i < readBlogs.length; i++) readBlogs[i].addEventListener('click', () => window.location.href = '/blog')
about.addEventListener('click', () => window.location.href = '/about')
websites.helpinghands.addEventListener('click', () => window.location.href = 'https://helpinghandsadultcare.org/')
websites.goodhandhauling.addEventListener('click', () => window.location.href = 'https://goodhandhauling.com/')
}
}
new Index().Init()
|