Try windows build first, then webgl, to have a backup build for your game if it keeps crashing when building to webgl.
Viewing post in Weird error preventing my builds from running
Sorry bro, can't really help you that much. I can only give you a suggestion, although it's up to you if you want to.
- If you know StackOverflow or UnityForums, you can search or ask there. I recommend this before doing anything else.
- Try to reinvent the game to another game project, not the best solution.
I have game project before that was re-imported to another Unity Version (newer than back to older). The project too was corrupted.