How can I interpolate JSX with an expression in a string?

后端 未结 2 479
天命终不由人
天命终不由人 2020-12-28 11:40

Looking to achieve the following:

Obviously this compiles to:

2条回答
  •  长情又很酷
    2020-12-28 12:12

    You could use a react expression and then the javascript es6 string interpolation

    Something like this:

提交回复
热议问题