Skip to content

Commit

Permalink
perf: optimize header shrink handle logic
Browse files Browse the repository at this point in the history
  • Loading branch information
XPoet committed Sep 26, 2023
1 parent 134c99f commit e7064e5
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion source/js/header-shrink.js
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ KEEP.initHeaderShrink = () => {
isHeaderShrink: false,

init() {
this.headerHeight = this.headerDom.getBoundingClientRect().height
this.headerHeight = this.headerDom?.getBoundingClientRect()?.height || 70
},

headerShrink() {
Expand Down

0 comments on commit e7064e5

Please sign in to comment.