1
1

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?

More than 3 years have passed since last update.

Chrome検証ツールで他デバイスの画面サイズをエミュレートする(ための情報の調べ方)

Last updated at Posted at 2020-09-16

※キーボードショートカットはMac版Chromeの場合の情報です。

手順

  1. 検証ツールを開く。(F12またはCommand+Shift+i
  2. Toggle device toolbarを表示する。(Command+Shift+m
  3. デバイス選択欄(初期値が「Responsive」のところ)をクリックして、**Edit...**を選択する。
  4. **Add custom device...**ボタンを押す。
  5. 必要情報を記入して、Addボタンを押す。
  6. デバイス選択欄をクリックして、追加したデバイスを選択する。

必要情報の調べ方

エミュレート対象の機種がオンラインの場合

IPアドレスや画面解像度など確認くんから下記項目を確認する。

エミュレート対象の機種がオフラインの場合
  1. 検証ツールを開く。(F12またはCommand+Shift+i
  2. Consoleタブに切り替えて、下記を入力(=取得)して調べる。

Width: window.document.body.clientWidth
Height: window.document.body.clientHeight
Device pixel ratio: window.devicePixelRatio
User agent string: window.navigator.userAgent

1
1
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
1
1

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?