gpt4 book ai didi

json - 我实际上如何在 Spotify 应用程序中设置默认选项卡?

转载 作者:行者123 更新时间:2023-12-01 00:33:00 25 4
gpt4 key购买 nike

The integration guidlines for the Spotify Apps API提到了 DefaultTabs 以及它应该如何在 manifest.json 文件中表达以在您的 Spotify 应用程序中实现制表符。不幸的是,我在让它工作时遇到问题,并且它引用的应用程序(标签,带有 URI spotify:app:tabs)例如在我的 Spotify 应用程序预览版本中不存在。

The application can specify what tabs it wants in the manifest file, in the DefaultTabs attribute. The attribute must be a list of records. Each record must contain the attributes arguments and title. The title can, and should, be localized by making it into a record with attributes for each language (currently en, fr and es).

我尝试了以下方法:

  1. 将这段代码添加到我的 manifest.json 文件中:

    "DefaultTabs": [{
    arguments: [],
    title: {"en": "På TV4"}
    }
    ]
  2. 退出并重新加载 Spotify 应用程序。

  3. 通过在地址字段中输入地址 spotify:app:name 来加载我的应用。

在这里,我希望看到选项卡已加载,但事实并非如此。任何有关正确语法的帮助将不胜感激。

最佳答案

起初我也遇到了一些问题,但以下代码片段对我有用:

"DefaultTabs": [
{
"arguments": "test",
"title": { "en": "test" }
},
{
"arguments": "test2",
"title": { "en": "test2" }
}
]

我认为您可能遗漏了参数。

另请查看 GitHub 中的 Kitchensink 演示应用程序和源代码:https://github.com/ptrwtts/kitchensink

关于json - 我实际上如何在 Spotify 应用程序中设置默认选项卡?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/8975028/

25 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com