How do you debug the Javascript as it is minify?

Hi there,

all is in the title, How do you debug the Javascript code as it is minify ?
In other word, how to do you distinguish the dev env from the prod env ?

thanks for any insight
Cheers
Chris