The (new) age old question.
Why people say yes:
If you are a designer who codes, you are a unicorn. You can do anything short of magic because you can own every aspect of your product and process.
Why others say no:
Many believe coding won't be a super power anymore because it's getting easier and more democratized. Designers should focus on being good designers.
Designers should understand code because it is a crucial tool. However, a designer should never be beholden to tools because they change too often.