compiler/endpoints/typeUtil.ts
Florian Bouillon ef866401a4
Moved files to link with the SDK
Signed-off-by: Avior <florian.bouillon@delta-wings.net>
2020-03-11 11:21:40 +01:00

11 lines
344 B
TypeScript

import Type, { TypeSimple } from "@tcgdex/sdk/interfaces/Type";
import LangList, { Langs } from "@tcgdex/sdk/interfaces/LangList";
import TranslationUtil from "@tcgdex/sdk/TranslationUtil";
export function typeToTypeSimple(type: Type, lang: Langs): TypeSimple {
return {
id: type,
name: TranslationUtil.translate("type", type, lang)
}
}