When you click to view the work page, the url in the browser changes and the page does not jump, but the work details page is displayed, and the work can be switched between the left and right. how can this effect be achieved.
When you click to view the work page, the url in the browser changes and the page does not jump, but the work details page is displayed, and the work can be switched between the left and right. how can this effect be achieved.
Reply content:
When you click to view the work page, the url in the browser changes and the page does not jump, but the work details page is displayed, and the work can be switched between the left and right. how can this effect be achieved.
--- Update ---
After checking the url, the Js method is used to change the url.Window. history. pushState ()For more information, see the link description. For example, enter:
Window. history. pushState ('q1000', 'title', '/q/123 ');
You can change the current url without reloading the page. Simply change the title.
Document. title = 'question100'This type of user interaction is worth learning from.
You can see how network requests are implemented. Is it asynchronous loading? Or HTTP 2?