Skip to content

Commit

Permalink
Use classList.add() instead of className =
Browse files Browse the repository at this point in the history
  • Loading branch information
Naviary2 committed Jan 3, 2025
1 parent c44aa83 commit 5d888a3
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions src/client/scripts/esm/views/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -36,14 +36,14 @@ interface Contributor {
iconImg.src = contributor.iconUrl;

const githubStatsContainer = document.createElement("div");
githubStatsContainer.className = "github-stats";
githubStatsContainer.classList.add("github-stats");

const name = document.createElement("p");
name.className = "name";
name.classList.add("name");
name.innerText = contributor.name;

const paragraph = document.createElement("p");
paragraph.className = "contribution-count";
paragraph.classList.add("contribution-count");
paragraph.innerText = `${translations['contribution_count']?.[0] || ""}${contributor.contributionCount}${translations['contribution_count']?.[1] || ""}`;

githubStatsContainer.appendChild(name);
Expand Down

0 comments on commit 5d888a3

Please sign in to comment.