I swear everything was working fine a few months ago. And then I picked up developing my app again lately and now I can't get universal links working on ios. Android is fine, but no luck on ios. Not sure if it's the latest flutter, the latest uni_links or the latest ios. But I just can't get it working properly on ios.
Yes, I updated the my apple-app-site-association to include the new recommended format (and keep the old one there are well), like:
{
"applinks": {
"apps": [],
"details": [
{
"appID": "Z1239YU75.com.mycomp.mysubdomain",
"paths": [ "/mysubdomain.mycomp.com/*" ],
"appIDs": ["Z1239YU75.com.mycomp.mysubdomain"],
"components": [
{
"/": "/mysubdomain.mycomp.com/*"
}
]
}
]
}
}
(and I can curl my subdomain and the file is serverd properly, no redirect)
My Runner.entitlements looks correct:
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>aps-environment</key>
<string>development</string>
<key>com.apple.developer.associated-domains</key>
<array>
<string>applinks: mysubdomain.mycomp.com </string>
</array>
</dict>
</plist>
I just can't get it to work. I tried on the simu, on the phone, with testflight... nothing works on ios, it keeps opening in safari (and android works properly...)
This is what I tried on the simu if you are curious: xcrun simctl openurl booted 'https://mysubdomain.mycomp.com/abcd'
In case you asked, here is flutter doctor:
>> flutter doctor -v
[✓] Flutter (Channel stable, 1.20.3, on Mac OS X 10.15.6 19G2021, locale es-ES)
• Flutter version 1.20.3 at /Users/didier/tmp/flutter
• Framework revision 216dee60c0 (hace 2 semanas), 2020-09-01 12:24:47 -0700
• Engine revision d1bc06f032
• Dart version 2.9.2
[✓] Android toolchain - develop for Android devices (Android SDK version 29.0.2)
• Android SDK at /Users/didier/Library/Android/sdk
• Platform android-30, build-tools 29.0.2
• ANDROID_HOME = /Users/didier/Library/Android/sdk
• ANDROID_SDK_ROOT = /Users/didier/Library/Android/sdk
• Java binary at: /Applications/Android Studio.app/Contents/jre/jdk/Contents/Home/bin/java
• Java version OpenJDK Runtime Environment (build 1.8.0_202-release-1483-b49-5587405)
• All Android licenses accepted.
[✓] Xcode - develop for iOS and macOS (Xcode 11.7)
• Xcode at /Applications/Xcode.app/Contents/Developer
• Xcode 11.7, Build version 11E801a
• CocoaPods version 1.9.1
[✓] Android Studio (version 3.5)
• Android Studio at /Applications/Android Studio.app/Contents
• Flutter plugin version 42.1.1
• Dart plugin version 191.8593
• Java version OpenJDK Runtime Environment (build 1.8.0_202-release-1483-b49-5587405)
[✓] IntelliJ IDEA Ultimate Edition (version 2020.2.1)
• IntelliJ at /Applications/IntelliJ IDEA.app
• Flutter plugin version 49.0.4
• Dart plugin version 202.7206
[✓] VS Code (version 1.39.2)
• VS Code at /Applications/Visual Studio Code.app/Contents
• Flutter extension version 3.4.1
[✓] Connected device (1 available)
• iPhone 11 (mobile) • CF71C2E0-11E3-44D2-A1B0-45CCBDF9B84C • ios • com.apple.CoreSimulator.SimRuntime.iOS-13-7 (simulator)
• No issues found!