Override geolocation with the Sensors tool
Many websites take advantage of user location in order to provide a more relevant experience for the users. For example, a weather website may show the local forecast in a user's area, after the user has granted the website permission to access the current user location.
If you are building a UI that changes depending on where the user is located, you probably want to make sure that the site behaves correctly in different places around the world. To override your geolocation in Microsoft Edge DevTools:
Press Ctrl+Shift+P (Windows, Linux) or Command+Shift+P (macOS) to open the Command Menu.
Type
sensors
, select Show Sensors, and then press Enter. The Sensors tool opens at the bottom of the DevTools window.Click the Location dropdown list, and then:
- Select a city, such as
Tokyo
. - Click Other to enter custom longitude and latitude coordinates.
- Click Location unavailable to see how your site behaves when the user's location isn't available.
- Select a city, such as
Note
Portions of this page are modifications based on work created and shared by Google and used according to terms described in the Creative Commons Attribution 4.0 International License. The original page is found here and is authored by Kayce Basques (Technical Writer, Chrome DevTools & Lighthouse).
This work is licensed under a Creative Commons Attribution 4.0 International License.
피드백
https://aka.ms/ContentUserFeedback
출시 예정: 2024년 내내 콘텐츠에 대한 피드백 메커니즘으로 GitHub 문제를 단계적으로 폐지하고 이를 새로운 피드백 시스템으로 바꿀 예정입니다. 자세한 내용은 다음을 참조하세요.다음에 대한 사용자 의견 제출 및 보기