1.安装
npm install driver.js
2.
import { driver } from 'driver.js';
import 'driver.js/dist/driver.css';
const driverObj = driver({showProgress: true,steps: [{element: '.keywords',popover: {title: 'Title',description: 'Description',side: 'left',align: 'start'}},{element: '.clientId',popover: {title: 'Title',description: 'Description',side: 'bottom',align: 'start'}},{element: '.Search',popover: {title: 'Title',description: 'Description',side: 'top',align: 'start'}}]
});
driverObj.drive();
官方文档:Driver.js 中文文档 | Driver.js 中文网