Skip to content

Commit

Permalink
Fix styled-components displayLabel issue
Browse files Browse the repository at this point in the history
  • Loading branch information
damassi committed Jan 21, 2018
1 parent af2442f commit b7eb6fb
Show file tree
Hide file tree
Showing 3 changed files with 15 additions and 5 deletions.
11 changes: 8 additions & 3 deletions .babelrc
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,6 @@
"stage-3"
],
"plugins": [
"babel-plugin-rewire",
"inline-react-svg",
"transform-runtime",
["module-resolver", {
Expand All @@ -20,10 +19,16 @@
"env": {
"development": {
"plugins": [
["styled-components", {
"ssr": true
["babel-plugin-styled-components", {
"ssr": true,
"displayName": true
}]
]
},
"test" : {
"plugins": [
"babel-plugin-rewire"
]
}
}
}
2 changes: 0 additions & 2 deletions desktop/apps/webpack/components/App.js
Original file line number Diff line number Diff line change
Expand Up @@ -7,8 +7,6 @@ const Container = styled.div`
color: white;
`

Container.displayName = 'Container'

export class App extends Component {
render () {
return (
Expand Down
7 changes: 7 additions & 0 deletions test/test.config.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,11 @@
const path = require('path')

require('raf/polyfill')

require('dotenv').config({
path: path.join(process.cwd(), '.env.test')
})

const Adapter = require('enzyme-adapter-react-16')
const Enzyme = require('enzyme')

Expand Down

0 comments on commit b7eb6fb

Please sign in to comment.