How to map values from app.config to scala object and used it

how to map scala object with application.conf properties and reading controllers

app.conf has follow propertiest:

emp {
name: “sam”,
salary: 200

case class Emp(name:String, salary:Double)

What you need is basically a macro to read the config properties based on the fields in the case class. There are a few libraries out there that provide this functionality, for example:

If you’re looking for something very minimal on top of Play, I wrote, but the features of the above two libraries are far more extensive.