Skip to content
This repository has been archived by the owner on Feb 5, 2023. It is now read-only.

Commit

Permalink
chore: customize icon and document title
Browse files Browse the repository at this point in the history
  • Loading branch information
Candinya committed Sep 7, 2021
1 parent c6c5d3a commit be10439
Show file tree
Hide file tree
Showing 3 changed files with 10 additions and 1 deletion.
1 change: 1 addition & 0 deletions src/assets/index.ejs
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@
<meta http-equiv="X-UA-Compatible" content="IE=edge" />
<meta name="viewport" content="width=device-width,initial-scale=1.0" />
<title>Web3 Pass</title>
<link rel='icon' type='image/x-icon' id='favicon' href='/favicon.ico' />
</head>
<body>
<div id="app"></div>
Expand Down
8 changes: 8 additions & 0 deletions src/views/Home.vue
Original file line number Diff line number Diff line change
Expand Up @@ -315,6 +315,14 @@ export default class Home extends Vue {
this.rss3Profile.bio = profile?.bio || '';
this.rss3Profile.address = this.ethAddress;
if (profile?.avatar?.[0]) {
const favicon = <HTMLLinkElement>document.getElementById('favicon');
favicon.href = profile.avatar[0];
}
if (profile?.name) {
document.title = profile.name;
}
if (data) {
this.accounts.push({
platform: 'Ethereum',
Expand Down
2 changes: 1 addition & 1 deletion webpack.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -91,7 +91,7 @@ module.exports = (env, argv) => ({
chunks: ['index'],
filename: 'index.html',
title: 'RSS3 Page',
favicon: 'public/favicon.ico',
// favicon: 'public/favicon.ico',
hash: true,
template: 'src/assets/index.ejs',
}),
Expand Down

0 comments on commit be10439

Please sign in to comment.