Quantcast
Channel: CodeSection,代码区,Python开发技术文章_教程 - CodeSec
Viewing all articles
Browse latest Browse all 9596

Reconciling Django Templates with React Components

$
0
0
How to build your frontend without making a Single-Page-App

At $startupNameHere we decided to write our backend in Django and our frontend in React. The combination is not unusual these days, but if you’ve ever tried it you’ve probably found there’s some friction between page composition with Django’s template system, and React’s component model.

The fundamental issue is that Django wants you to build up your pages using template fragments, and React wants to pull you into its world with JS components as the main building blocks.


Reconciling Django Templates with React Components

I’m here to tell you these don’t necessarily have to conflict, it’s possible to use both without angering the Lilliputians.


Viewing all articles
Browse latest Browse all 9596

Trending Articles