Khi chạy ion phục vụ tôi thấy điều này:ion phục vụ bắt đầu vào localhost và không phải là máy chủ IP
Gulp startup tasks: [ 'sass', 'watch' ]
Running dev server: http://localhost:8100
Running live reload server: http://localhost:35729
Watching : [ 'www/**/*', '!www/lib/**/*' ]
Ionic server commands, enter:
restart or r to restart the client app from the root
goto or g and a url to have the app navigate to the given url
consolelogs or c to enable/disable console log output
serverlogs or s to enable/disable server log output
quit or q to shutdown the server and exit
Có nghĩa là tôi không thể truy cập các ứng dụng từ một trình duyệt như nó chỉ nghe cho localhost. Làm thế nào tôi có thể thay đổi localhost thành IP máy chủ thực tế?
Cảm ơn
Thank you very much Tôi không có ý tưởng làm thế nào tôi bị mất rằng :) – lulu88
Woah, tôi nhận được không có đầu ra từ 'address' ion vì vậy tôi đã sử dụng 'ionic serve -address xx.xx.xx.xx' (127.0.0.1/localhost là những gì tôi muốn) – Jacksonkr