This repository was archived by the owner on May 14, 2021. It is now read-only.
File tree 3 files changed +12
-4
lines changed
3 files changed +12
-4
lines changed Original file line number Diff line number Diff line change @@ -45,7 +45,7 @@ const isLastLineWhitespaceOnly = text => {
45
45
return false
46
46
}
47
47
}
48
- return true
48
+ return false
49
49
}
50
50
51
51
// eslint-disable-next-line no-return-assign
Original file line number Diff line number Diff line change @@ -71,3 +71,11 @@ const Button6 = styled.button`
71
71
` }
72
72
background: blue;
73
73
`
74
+
75
+ // multi interpolations within a property
76
+ const borderWidth = '1px'
77
+ const borderStyle = 'solid'
78
+ const Button7 = styled . button `
79
+ width: 20px;
80
+ border: ${ borderWidth } ${ borderStyle } ${ color } ;
81
+ `
Original file line number Diff line number Diff line change @@ -41,15 +41,15 @@ describe('utils', () => {
41
41
42
42
describe ( 'isLastLineWhitespaceOnly' , ( ) => {
43
43
it ( 'should return true for empty string' , ( ) => {
44
- expect ( isLastLineWhitespaceOnly ( '' ) ) . toEqual ( true )
44
+ expect ( isLastLineWhitespaceOnly ( '' ) ) . toEqual ( false )
45
45
} )
46
46
47
47
it ( 'should return true for string of spaces' , ( ) => {
48
- expect ( isLastLineWhitespaceOnly ( ' ' ) ) . toEqual ( true )
48
+ expect ( isLastLineWhitespaceOnly ( ' ' ) ) . toEqual ( false )
49
49
} )
50
50
51
51
it ( 'should return true for string of spaces and tabs' , ( ) => {
52
- expect ( isLastLineWhitespaceOnly ( ' \t ' ) ) . toEqual ( true )
52
+ expect ( isLastLineWhitespaceOnly ( ' \t ' ) ) . toEqual ( false )
53
53
} )
54
54
55
55
it ( 'should return false for string with something other than space and tab' , ( ) => {
You can’t perform that action at this time.
0 commit comments