content static method

Future<String> content(
  1. String text, {
  2. String locale = 'vi',
})

Implementation

static Future<String> content(String text, {String locale = 'vi'}) async {
  final localeLocal = prefsHelper.getLocale();
  return locale.isNotEmpty == true ? (await text.translate(from: locale, to: localeLocal)).text : (await text.translate(to: localeLocal)).text;
}