Take a look at the talk where the concepts behind React are introduced:<p><a href="https:&#x2F;&#x2F;www.youtube.com&#x2F;watch?v=x7cQ3mrcKaY" rel="nofollow">https:&#x2F;&#x2F;www.youtube.com&#x2F;watch?v=x7cQ3mrcKaY</a><p>It turns out there is no good reason to separate code and templates, because they are intrisically linked; one cannot work without the other. The separation should rather happen on units that are really independent, such as 2 separate pages of your application.