I've encountered an issue recently where I want to use a 3rd party plugin in my nextjs practice project. Please note that I'm a React beginner, therefore, I'm having a hard time wrapping my mind around the 'react way' of doing things.
My problem is that I do not know how to properly initialize/configure a plugin in a project.
For example, I want to use this smoothscroll js plugin. The regular static site approach is to add a script tag in the html files, and then initialize it by calling the plugin. eg:
<script type="text/javascript">
new GambitSmoothScroll({
amount: 150, // The scroll amount
speed: 900 // The scroll speed
});
</script>
But in react, this approach does not work because of the virtual DOM. Any pointers would be greatly appreciated!