Open in app
Kevin Kim
222 Followers
About

Sign in

222 Followers
About
Open in app

Inline JSX Style I always forget

Kevin Kim

Kevin Kim

Nov 27, 2019·1 min read

For when I just want to do a quick and dirty check of styling getting implemented properly, this is the JSX convention I should follow:

function HelloHeader() {
return <h1 style={{color: "red", fontSize: "16px"}}>Hello World!</h1>
}

Two curly braces, and then camelCase everything.

Source:

https://dev.to/ceceliacreates/inline-styling-with-jsx-20k0

Kevin Kim

Front End Engineer https://kevinyckim.netlify.com/

  • React
  • CSS

More from Kevin Kim

Front End Engineer https://kevinyckim.netlify.com/

More From Medium

Setting up Webflow on Ruby on Rails

Kevin Kim

How to set up SonarQube locally on a React Typescript Project

André Borba Netto Assis in JavaScript in Plain English

Get Sass and Font Awesome up and running on your Create React App in 5 minutes

Kevin Kim

React Context API Vs Redux

Nithya Yamasinghe

FizzBuzzBazz: How to answer and how NOT to answer

Kevin Kim in ITNEXT

Cross-site Scripting (XSS) simplified: What is it & how to prevent it?

DLT Labs

How to Make Your Django Forms Look Crispy 🥓

Ordinary Coders

NYTimes Peru N-Word, Part Three: What Happened in the 2019 Investigation?

Donald G. McNeil Jr.

About

Help

Legal

Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store