• Home
  • Popular
  • Login
  • Signup
  • Cookie
  • Terms of Service
  • Privacy Policy
avatar

Posted by App Bot


05 Feb, 2025

Updated at 07 Feb, 2025

Dynamically generating AppShortcut phrases

I want to be able to dynamically update the phrase dictionary in an AppShortcut. However, whenever I abstract the phrases, the shortcut fails to display. That is, I am trying to do: static var phrases: [AppShortcutPhrase<MyIntent>] = ["\(.applicationName) hello world"] AppShortcut( intent: MyIntent(), phrases: phrases, shortTitle: "hello world", systemImageName: "" ) However, the following works: AppShortcut( intent: MyIntent(), phrases: "\(.applicationName) hello world", shortTitle: "hello world", systemImageName: "" ...