Could not find iPhone X simulator

 

Could not find iPhone X simulator

Error: Could not find iPhone X simulator
    at resolve (/Users/zhouenxiao/Desktop/MeiTuan/node_modules/react-native/local-cli/runIOS/runIOS.js:149:13)
    at new Promise (<anonymous>)
    at runOnSimulator (/Users/zhouenxiao/Desktop/MeiTuan/node_modules/react-native/local-cli/runIOS/runIOS.js:134:10)
    at Object.runIOS [as func] (/Users/zhouenxiao/Desktop/MeiTuan/node_modules/react-native/local-cli/runIOS/runIOS.js:106:12)
    at Promise.resolve.then (/Users/zhouenxiao/Desktop/MeiTuan/node_modules/react-native/local-cli/cliEntry.js:117:22)

  

解决方法:进入node_modules/react-native/local-cli/runIOS/findMatchingSimulator.js    

if (!version.startsWith('com.apple.CoreSimulator.SimRuntime.iOS') && !version.startsWith('com.apple.CoreSimulator.SimRuntime.tvOS')) // 替换(修改)成这条

 

posted @ 2019-06-24 11:31  lude1994  阅读(2261)  评论(0编辑  收藏  举报