File tree Expand file tree Collapse file tree 2 files changed +1
-26
lines changed
Expand file tree Collapse file tree 2 files changed +1
-26
lines changed Original file line number Diff line number Diff line change @@ -104,7 +104,7 @@ const Header = ({ hiddenAd, showAd }: Props) => {
104104 { t ( 'header.periodical' ) }
105105 </ HeaderBtn >
106106 </ li >
107- < li className = { liClassName ( '/report/tiobe ' ) } >
107+ < li className = { liClassName ( '/report' ) } >
108108 < RankButton t = { t } />
109109 </ li >
110110 < li className = { liClassName ( '/article' ) } >
Original file line number Diff line number Diff line change @@ -2,8 +2,6 @@ import { AppProps } from 'next/app';
22import { useRouter } from 'next/router' ;
33import Script from 'next/script' ;
44import { appWithTranslation } from 'next-i18next' ;
5- import NProgress from 'nprogress' ;
6- import { useEffect } from 'react' ;
75
86import 'nprogress/nprogress.css' ;
97import '@/styles/globals.css' ;
@@ -27,29 +25,6 @@ function MyApp({ Component, pageProps }: AppProps) {
2725 // 需要单页面展示的路由
2826 const singlePage : string [ ] = [ '/404' , '/500' ] ;
2927
30- // 页面跳转时的加载进度条
31- useEffect ( ( ) => {
32- // 不显示右上角的加载转圈图标
33- NProgress . configure ( { showSpinner : false } ) ;
34- const handleStart = ( ) => {
35- NProgress . start ( ) ;
36- } ;
37-
38- const handleStop = ( ) => {
39- NProgress . done ( ) ;
40- } ;
41-
42- router . events . on ( 'routeChangeStart' , handleStart ) ;
43- router . events . on ( 'routeChangeComplete' , handleStop ) ;
44- router . events . on ( 'routeChangeError' , handleStop ) ;
45-
46- return ( ) => {
47- router . events . off ( 'routeChangeStart' , handleStart ) ;
48- router . events . off ( 'routeChangeComplete' , handleStop ) ;
49- router . events . off ( 'routeChangeError' , handleStop ) ;
50- } ;
51- } , [ router ] ) ;
52-
5328 return (
5429 < div id = 'root' >
5530 < Script id = 'baidu-analytics' >
You can’t perform that action at this time.
0 commit comments