我正在开发一个响应式的 Web 应用程序。我可以使用 chrome 移动仿真选项将浏览器启动到我需要的配置中。但是由于没有在 Chrome 选项上设置响应,我没有得到想要的结果。
这是我的代码。根据移动仿真选项,我可以使用预定义的设备配置或使用设备指标来配置分辨率。但我需要在 chrome 中使用响应式选项。我怎么能做到这一点?
我的意思是在设备下拉菜单中使用响应式

Map<String, Object> deviceMetrics = new HashMap<>();
deviceMetrics.put("width", 320);
deviceMetrics.put("height", 533);
Map<String, Object> mobileEmulation = new HashMap<>();
mobileEmulation.put("deviceMetrics", deviceMetrics);
ChromeOptions options = new ChromeOptions()
options.setExperimentalOption("mobileEmulation",mobileEmulation);