标签: typescript promise readonly sonarlint
我有一个返回 Readonly<Promise<ListClusters>>
Readonly<Promise<ListClusters>>
我使用 SonarLint 触发警告 SonarLint: Refactor this redundant 'await' on a non-promise.
SonarLint: Refactor this redundant 'await' on a non-promise.
但我觉得这是误报。这是对的吗?如果是,如何在不完全消除警告的情况下更正 SonarLint?
Readonly 在这里的作用是什么?
Readonly