Hey folks! What's the difference between translate and margin in terms of positioning in CSS? | Sololearn: Learn to code for FREE!
New course! Every coder should learn Generative AI!
Try a free lesson
0

Hey folks! What's the difference between translate and margin in terms of positioning in CSS?

CSS

2nd Mar 2021, 11:14 AM
Jonel Hatwell
Jonel Hatwell - avatar
2 Answers
+ 3
translate move element without affecting structure margin affect structure you could also use 'float' property, or 'position' (set to 'relative', absolute', 'fixed'...) and use one or more of 'top', 'left', 'bottom', 'right'
2nd Mar 2021, 11:20 AM
visph
visph - avatar
+ 2
Jonel Hatwell You posted 3 copies of this question (including this one). Please remove the other copies to help reduce duplicated questions 👍 Also please tag a relevant language name ☝
2nd Mar 2021, 11:40 AM
Ipang