Fix eslint error of import/no-extraneous-dependencies (#11884)
* Fix eslint error of import/no-extraneous-dependencies - Add history dependency * refactoring code
This commit is contained in:
parent
4f6af87906
commit
d0c2c52783
3 changed files with 35 additions and 2 deletions
|
@ -31,10 +31,10 @@ function main() {
|
|||
const React = require('react');
|
||||
const ReactDOM = require('react-dom');
|
||||
const Rellax = require('rellax');
|
||||
const createHistory = require('history').createBrowserHistory;
|
||||
const { createBrowserHistory } = require('history');
|
||||
|
||||
const scrollToDetailedStatus = () => {
|
||||
const history = createHistory();
|
||||
const history = createBrowserHistory();
|
||||
const detailedStatuses = document.querySelectorAll('.public-layout .detailed-status');
|
||||
const location = history.location;
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue