refactor: load Twitch emotes from Helix (#5239)

This commit is contained in:
nerix
2024-09-01 11:22:54 +02:00
committed by GitHub
parent 03b0e4881f
commit 820aa12af6
40 changed files with 1251 additions and 528 deletions
+22
View File
@@ -0,0 +1,22 @@
#pragma once
#include <nonstd/expected.hpp>
class QString;
namespace chatterino {
template <typename T, typename E>
using Expected = nonstd::expected_lite::expected<T, E>;
template <typename T>
using ExpectedStr = Expected<T, QString>;
// convenience function from nonstd/expected.hpp
template <typename E>
constexpr nonstd::unexpected<std::decay_t<E>> makeUnexpected(E &&value)
{
return nonstd::unexpected<std::decay_t<E>>(std::forward<E>(value));
}
} // namespace chatterino