parseFontWeight function
sorta like an enum
Implementation
FontWeight? parseFontWeight(String? string) {
FontWeight? rst;
FontWeight.values.forEach((element) {
if (string == element.toJson()) {
rst = element;
}
});
return rst;
}