committed by
GitHub
parent
de040e6727
commit
27659baca6
9
website/gatsby-browser.js
Normal file
9
website/gatsby-browser.js
Normal file
@ -0,0 +1,9 @@
|
||||
// Make scroll behavior of internal links smooth
|
||||
exports.onClientEntry = () => {
|
||||
const SmoothScroll = require('smooth-scroll');
|
||||
new SmoothScroll('a[href*="#"]', {
|
||||
offset() {
|
||||
return document.querySelector('#header').offsetHeight;
|
||||
},
|
||||
});
|
||||
};
|
Reference in New Issue
Block a user