It can be done both ways really depending on your setup, knowledge, intent on use and preferred methods. And how you are extracting is also crucial and good to know (ISO, BHO, CO2, etc.).
You can decarb prior to extraction if doing and ISO extract AND not cooking with it (not applying heat)...