1 line
2.7 KiB
Plaintext
1 line
2.7 KiB
Plaintext
{"version":3,"sources":["android.js"],"names":["constructManifestUrlAsync","process","cwd","address","withTimestamp","openProjectAsync","success","error","generate","green","qrCode","underline","cyan","red","message","startAndroidAndPrintInfo","validation","reactNativeVersionWarnings","developerTool","offline","run"],"mappings":";;;;;;;;;;AAmBA;;sFACA;AAAA;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,mBACwB,cAASA,yBAAT,CAAmCC,QAAQC,GAAR,EAAnC,CADxB;;AAAA;AACQC,mBADR;;AAEE,0BAAIC,aAAJ,CAAkB,qBAAlB;;AAFF;AAAA,mBAImC,aAAQC,gBAAR,CAAyBJ,QAAQC,GAAR,EAAzB,CAJnC;;AAAA;AAAA;AAIUI,mBAJV,SAIUA,OAJV;AAImBC,iBAJnB,SAImBA,KAJnB;;;AAME,qCAAGC,QAAH,CAAYL,OAAZ,EAAqB,kBAAU;AAC7B,4BAAIC,aAAJ,MAAqB,gBAAMK,KAAN,CAAY,mBAAZ,CAArB;AACA,kLAKF,4BAAOC,MAAP,EAAe,CAAf,CALE,sEASA,gBAAMC,SAAN,CAAgB,gBAAMC,IAAN,CAAWT,OAAX,CAAhB,CATA,oIAY8C,gBAAMQ,SAAN,CAAgB,gBAAMC,IAAN,CAAW,iBAAX,CAAhB,CAZ9C;AAiBD,aAnBD;;AAqBA,gBAAI,CAACN,OAAL,EAAc;AACZ,iCAAI,gBAAMO,GAAN,CAAUN,MAAMO,OAAhB,CAAJ;AACD;;AA7BH;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,G;;kBAAeC,wB;;;;;AAlBf;;AAEA;;;;AACA;;;;AACA;;;;AACA;;;;AACA;;;;AACA;;;;AAEA;;;;;;AAEA,YAAOC,UAAP,CAAkBC,0BAAlB,GAA+C,KAA/C;AACA,YAAOC,aAAP,GAAuB,MAAvB;AACA,YAAOC,OAAP,GAAiB,IAAjB;;AAEA,mBAASC,GAAT,CAAaL,wBAAb","file":"android.js","sourcesContent":["// @flow\n\nimport { Android, Config, ProjectSettings, UrlUtils } from 'xdl';\n\nimport chalk from 'chalk';\nimport indent from 'indent-string';\nimport path from 'path';\nimport pathExists from 'path-exists';\nimport qr from 'qrcode-terminal';\nimport log from '../util/log';\n\nimport packager from '../util/packager';\n\nConfig.validation.reactNativeVersionWarnings = false;\nConfig.developerTool = 'crna';\nConfig.offline = true;\n\npackager.run(startAndroidAndPrintInfo);\n\n// print a nicely formatted message with setup information\nasync function startAndroidAndPrintInfo() {\n const address = await UrlUtils.constructManifestUrlAsync(process.cwd());\n log.withTimestamp('Starting Android...');\n\n const { success, error } = await Android.openProjectAsync(process.cwd());\n\n qr.generate(address, qrCode => {\n log.withTimestamp(`${chalk.green('Packager started!')}`);\n log(\n `\nTo view your app with live reloading, point the Expo app to this QR code.\nYou'll find the QR scanner on the Projects tab of the app.\n\n${indent(qrCode, 2)}\n\nOr enter this address in the Expo app's search bar:\n\n ${chalk.underline(chalk.cyan(address))}\n\nYour phone will need to be on the same local network as this computer.\nFor links to install the Expo app, please visit ${chalk.underline(chalk.cyan('https://expo.io'))}.\n\nLogs from serving your app will appear here. Press Ctrl+C at any time to stop.\n`\n );\n });\n\n if (!success) {\n log(chalk.red(error.message));\n }\n}\n"]} |