我们知道,在模块化开发中,关于引入类库或者组件的顺序问题是有共识的,一般是第三方类库在上方,本地文件在下方。但有时候没有注意到,eslint好强大库🤣,这都能给我发现。
import React, { useEffect, useRef, useState } from 'react';
// import axios from 'axios';
import styles from './style/index.module.less';
import history from '../../history';
import useLocale from '../../utils/useLocale';
import { useDispatch } from 'react-redux';
报错:
解决:
恢复正常