Custom Font weight in jetpack compose

my designer give me


which is 350. I am working on fonts through this doc. To provide FontWeight in FontFamily. I checked FontWeight.Light and FontWeight.Normal which is 300 and 400 respectively. So is there any solution for 350 ?


>Solution :

Its a class with parameterized constructor . You can just use it like this .

Font(resId = R.font.montserrat_light, weight = FontWeight(350))

Leave a Reply