Movatterモバイル変換


[0]ホーム

URL:


Skip to main content
AnOutSystems Company →
Site LogoSite Logo
Site LogoSite Logo
Version: v8

Previewing

There are many different options to test native functionality depending on your target platforms and needs.

Run Locally in a Web Browser

One of the most powerful features of Ionic is that the majority of your app development can happen right in a browser on your desktop. With full access to traditional web development tools (Chrome/Safari/Firefox dev tools), you can write code then test/debug it quickly without having to recompile or deploy to a simulator or device.

To do so, runionic serve from the command line in the project's directory:

$ionic serve
> ng run app:serve --host=0.0.0.0 --port=8100

[INFO] Development server running!

Local: http://localhost:8100
External: http://192.168.1.169:8100

Use Ctrl+C to quit this process

[INFO] Browser window opened to http://localhost:8100!

Withionic serve running, continue developing your app. As you save changes, the app reloads with those changes applied.

note

If the external link isn't listed on the terminal, then runionic serve --external to generate it.

When implementing native functionality, usePlatform Detection.When you're ready to test on a real device, see here foriOS andAndroid.

Simulating a Mobile Viewport

Each major browser vendor includes developer tools for mobile emulation. These tools offer the ability to change the emulated device type.

Chrome

Open your application at the local or remote address that it is being served from. For example,http://localhost:4200. Then, open the Chrome developer tools by pressingCtrl+Shift+I on Windows/Linux orCmd+Opt+I on Mac.

Chrome Dev Tools

From here you can select different device types from the dropdown, change the orientation of the device and throttle the network speed.

For additional features and information visit:https://developer.chrome.com/docs/devtools/device-mode/.

Safari

note

Prerequisites: Show Develop menu in menu bar option must be enabled in Safari Advanced options.

Open your application at the local or remote address that it is being served from. For example,http://localhost:4200. Select theDevelop menu in Safari and selectEnter Responsive Design Mode . Alternatively you can use the keyboard shortcutCmd+Opt+R.

Safari Responsive Design Mode

From here you can select different device types to emulate as well as change the orientation of the device.

For additional features and information visit:https://developer.apple.com/safari/tools/.

Firefox

Open your application at the local or remote address that it is being served from. For example,http://localhost:4200. Then, open the Firefox developer tools by pressingCtrl+Shift+M on Windows/Linux orCmd+Opt+M on Mac.

Firefox Responsive Design Mode

From here you can select different device types from the dropdown, change the orientation of the device and throttle the network speed.

For additional features and information visit:https://firefox-source-docs.mozilla.org/devtools-user/responsive_design_mode/.


[8]ページ先頭

©2009-2025 Movatter.jp