My javascript and html are definitely connected as i've run console.logs to test.
I have an onclick in my html which should run menu(). menu() is meant to remove my 'lanterns' element which is an image. However, nothing happens. There's no error either to help with debugging. I've also tried with the id for the parent #changetotext but I'm getting no response. I must be doing something fairly basic wrong.
function menu(){
var el = document.getElementById("lanterns");
el.remove();
};
<!doctype html>
<html lang="en">
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1">
<title>The Ludong Chinese Restaurant</title>
<meta name="description" content="The Ludong Chinese Restaurant">
<meta name="author" content="SitePoint">
<link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/bootstrap/4.0.0/css/bootstrap.min.css" integrity="sha384-Gn5384xqQ1aoWXA+058RXPxPg6fy4IWvTNh0E263XmFcJlSAwiGgFAW/dAiS6JXm" crossorigin="anonymous">
<link href="https://fonts.googleapis.com/css2?family=East+Sea+Dokdo&display=swap" rel="stylesheet">
<link rel="stylesheet" href="style.css">
</head>
<body>
<nav class="navbar navbar-expand-md bg-dark navbar-dark" id="top-bar">
<a class="navbar-brand" href="#">The Ludong</a>
</nav>
<div id="changetotext"><img src="https://res.cloudinary.com/dytmcam8b/image/upload/v1592684095/Chinese%20Restaurant/ludong.jpg"
alt="red lanterns" id="lanterns"></div>
<div class="padding1"></div>
<div class="bottom-menu d-flex flex-column flex-md-row justify-content-around flex-wrap">
<a href=""><div class="p-2 menuChoice" onclick="menu()">Menu</div></a>
<a href=""><div class="p-2 approach-choice">Approach</div></a>
<a href=""><div class="p-2 location-choice">Location</div></a>
<a href=""><div class="p-2 reservations-choice">Reservations</div></a>
<a href=""> <div class="p-2 gifts-choice">Gifts</div></a>
</div>
</div>
<script src="myscripts.js"></script>
</body>
</html>