A fix was implemented in the latest release (17.12.0). I found the answer here: https://developercommunity.visualstudio.com/t/Javascript-Files-Lose-Color-Coding-after/10687814. You'll need to go to Tools -> Options -> Text Editor -> Advanced, and update "TextMate parser line limit (required restart)".