+ 1

How do I align text in javascript if the words that are being displayed are only being coded in javascript, and nothing else.

https://code.sololearn.com/W5lP1hlDJ1PA/?ref=app

4th Jun 2018, 4:21 AM
Tyler Howell
Tyler Howell - avatar
3 odpowiedzi
+ 2
Dont know exactly but u can create a <p> or any other with js and make the text its children and then align it using js
4th Jun 2018, 4:29 AM
Rohit
Rohit - avatar
+ 1
add CSS body{ text-align: center; }
4th Jun 2018, 4:27 AM
Raj Chhatrala
Raj Chhatrala - avatar