JSFiddle - React, Tailwind, and code Playground

HTML

<button id="button" onclick="hide_edit_panel(56)">
Afficher le contenu
</button>

<div id="panel-edit" style="display: none">
Mon contenu
</div>

JavaScript

function hide_edit_panel(id)
{
  if (document.getElementById("panel-edit").style.display == 'none')
  {
  	document.getElementById("panel-edit").style.display = "block";
    	let maVar = test(id);
      alert(maVar);
  }
}

function test(id) {
	return "Voici la valeur de mon ID :" + id;
}