TeaSdk.ts
597 Bytes
import { AppSdk } from "./AppSdk";
import ObjectInstance from "../uitl/ObjectInstance";
/**
* 上报埋点⽇志
* 具体的打点需要跟运营联系
*/
export default class TeaSdk {
dot(key: string, value?) {
if (!value) {
value = '';
} else if (typeof (value) == 'object') {
value = JSON.stringify(value);
}
AppSdk.I.callApp('appDotLog', key, value);
}
static get I(): TeaSdk {
return ObjectInstance.get(TeaSdk) as TeaSdk;
}
}
export enum DotKey {
NativeAd = 'native_ad',
}