Skip to content

Instantly share code, notes, and snippets.

@mikedklein
Created November 7, 2016 04:12
Show Gist options
  • Save mikedklein/1054ec66cb7a676b7c1a42b1ed6f810f to your computer and use it in GitHub Desktop.
Save mikedklein/1054ec66cb7a676b7c1a42b1ed6f810f to your computer and use it in GitHub Desktop.
glamor style specificity
import React, { Component } from 'react';
import Button from 'react-bootstrap/lib/Button';
import { style } from 'glamor';
import logo from './logo.svg';
import './App.css';
const ButtonStyle = style({
borderTopLeftRadius: 0,
borderTopRightRadius: 0
});
class App extends Component {
render() {
return (
<div className="App">
<div className="App-header">
<img src={logo} className="App-logo" alt="logo" />
<h2>Welcome to React</h2>
</div>
<p className="App-intro">
To get started, edit <code>src/App.js</code> and save to reload.
</p>
<Button
type='submit'
className={`btn btn-primary ${ButtonStyle}`}
>
Go
</Button>
</div>
);
}
}
export default App;
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment