25 lines
455 B
JavaScript
Executable File
25 lines
455 B
JavaScript
Executable File
|
||
|
||
if ('scrollRestoration' in history) {
|
||
history.scrollRestoration = 'manual';
|
||
}
|
||
|
||
// 强制清空滚动位置(不依赖 body,直接操作 window)
|
||
window.scrollTo(0, 0);
|
||
|
||
import './bootstrap';
|
||
const $ = window.jQuery;
|
||
window.$ = $; // 确保全局一致性
|
||
|
||
import { fInitArticleLoader } from './modules/articles.js';
|
||
|
||
$(function() {
|
||
|
||
window.scrollTo(0, 0);
|
||
|
||
if ($.fn.infiniteScroll) {
|
||
fInitArticleLoader();
|
||
}
|
||
|
||
});
|