How to add custom html attributes in JSX

后端 未结 11 1927
南方客
南方客 2020-11-27 18:14

There are different reasons behind it, but I wonder how to simply add custom attributes to an element in JSX?

11条回答
  •  南方客
    南方客 (楼主)
    2020-11-27 18:45

    You can use the "is" attribute to disable the React attribute whitelist for an element.

    See my anwser here: Stackoverflow

提交回复
热议问题