无法在 React js 中为按钮添加 Tippy

Not able to add Tippy for a button in react js

我已经导入了下面的包,我尝试参考下面的 link,我不明白在哪里放置 tippy 代码。请帮助我。

https://atomiks.github.io/tippyjs/html-content

import React from 'react';
import ReactDom from 'react-dom';
import tippy from 'tippy.js';
import 'tippy.js/dist/tippy.css';

class Trial extentds Component {
    render(){
        return(
            <div>
                <Button onClick={this.submitTaggedFace} disabled={!this.validate()} variant="contained" color="primary"
                data-tippy="Tooltip"
                data-tippy-animation="scale"
                data-tippy-duration="0"
                data-tippy-arrow="true"
                data-tippy-delay="[800, 200]"
                >Click to Tag</Button>
            </div>
        )
    }
}

您的代码没有任何问题。您一定是在其他组件中遗漏了一些东西。

我创建了这个 codesandbox 示例:

https://codesandbox.io/s/5y8zm52own