📅  最后修改于: 2022-03-11 15:03:56.583000             🧑  作者: Mango
href={"#demo" + this.state.id}
//You can also use ES6 string interpolation/template literals with
//` (backticks) and ${expr} (interpolated expression),
href={`#demo${this.state.id}`}
source
https://stackoverflow.com/questions/39523040/concatenating-variables-and-strings-in-react