Skip to content

Commit c109d1f

Browse files
committed
fix: handle space and blank line after the tag. fixes #235
1 parent a5f970c commit c109d1f

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/transform.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -44,7 +44,7 @@ module.exports = function transform(
4444
) /* : Result */ {
4545
// Check if the file contains `css` or `styled` tag first
4646
// Otherwise we should skip transforming
47-
if (!/\b(styled(\([^)]+\)|\.[a-z0-9]+)|css)`/.test(content)) {
47+
if (!/\b(styled(\([^)]+\)|\.[a-z0-9]+)|css)[\s\n]*`/.test(content)) {
4848
return { code: content };
4949
}
5050

0 commit comments

Comments
 (0)