+ 8
Code Spacing
May I know why thrs space like <p class="serif"> This is a paragraph </p> Instead of typing <p class="serif"> this is a paragraph </p> Is there any difference? Thanks
4 odpowiedzi
+ 3
there isn't any difference between the two.
it's just a syntax habbit, some guys like their code with alot of spaces while some guys like their code with going one line down Everytime they adding something new.
+ 3
Ok thanks!
+ 2
it's all about code readability. this spacing called code indentation. by that you co-workers can easily read your code while development process. some developer minify them in just on line using npm packages for production server so it can be optimised for better speed
+ 1
if you use the spacing habbit it will reduce the time of finding the error in your code. sorry for the English