Skip to content

Instantly share code, notes, and snippets.

@taddison
Created December 12, 2019 15:01
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save taddison/5fb5cde18c550fde838de46db44455ec to your computer and use it in GitHub Desktop.
Save taddison/5fb5cde18c550fde838de46db44455ec to your computer and use it in GitHub Desktop.
React select with styled components
import React from "react";
import styled from "styled-components";
const MinorSelect = styled.select`
appearance: none;
background-color: #edf2f7;
border: 0.0625rem solid grey;
border-radius: 0.5rem;
font-size: 1.5rem;
padding: 1rem;
border-radius: 0;
`;
export default function Minor() {
return (
<div>
<MinorSelect>
<option>Option one</option>
<option>Option two</option>
<option>Option three</option>
</MinorSelect>
</div>
);
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment