File tree Expand file tree Collapse file tree 2 files changed +18
-2
lines changed Expand file tree Collapse file tree 2 files changed +18
-2
lines changed Original file line number Diff line number Diff line change @@ -7,7 +7,7 @@ const attributeName = '[a-zA-Z_:][a-zA-Z0-9:._-]*'
77const unquoted = '[^"\'=<>`\\u0000-\\u0020]+'
88const singleQuoted = "'[^']*'"
99const doubleQuoted = '"[^"]*"'
10- const jsProps = '{[^\n] *}'
10+ const jsProps = '{. *}'
1111const attributeValue =
1212 '(?:' +
1313 unquoted +
@@ -42,5 +42,6 @@ exports.tag = new RegExp(
4242 declaration +
4343 '|' +
4444 cdata +
45- ')'
45+ ')' ,
46+ 's'
4647)
Original file line number Diff line number Diff line change @@ -64,5 +64,20 @@ module.exports = [
6464 {
6565 description : 'Handles links' ,
6666 mdx : 'Hello, <Component>{props.world}</Component> and a moustache! }: <https://johno.com>'
67+ } ,
68+ {
69+ description : 'Handles multiline JSX blocks' ,
70+ mdx : `
71+ <Image
72+ src={asset(\`\${SOME_CONSTANT}/some.png\`)}
73+ width="123"
74+ height="456"
75+ caption={
76+ <span>
77+ Here's a caption
78+ </span>
79+ }
80+ />
81+ ` . trim ( )
6782 }
6883]
You can’t perform that action at this time.
0 commit comments