JSFiddle - React, Tailwind, and code Playground
by eapo
HTML
<div id="parent">
<div id="child1">
<a>
<img src="img\linkedin.png" alt="jhj" width="200px;" height="70px;" />
</a>
</div>
<div id="child2">
<a>Home</a>
<a>Examples</a>
<a>Tricks</a>
<a>Contact us</a>
</div>
</div>
<p> </p>
<p> </p>
<p> </p>
<p> </p>
<p> </p>
<p> </p>
<p> </p>
<p> </p>
<p> </p>
<p> </p>
<p> </p>
<p> </p>
<p> </p>
<p> </p>
<p> </p>
<p> </p>
<p> </p>
<p> </p>
<p> </p>
<p> </p>
CSS
#parent {
position: fixed;
width: 100%;
background-color: white;
left: 0;
}
#child1 {
left: 100px;
position: absolute;
}
#child2 {
position: relative;
top: 15;
left: 0;
margin-top: 0;
margin-left: 300px;
border: 1px solid red;
font-size:3em;
}