This is what I've tried:
const Footer = () => {
return (
<footer className='footer mt-5'>
<p> Copyright ©2022-<script>document.write(new Date().getFullYear())</script>
Laptop Inventories All Rights Reserved</p>
</footer>
);
};
const date = new Date(); const year = date.getFullYear();