Readplace

(Medium) Front-End Separation

Gist 1 min read
View original
  • current

This article is too short to summarise.

This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode characters

//=============================
// THE API BACK-END PROJECT
//=============================
const userDetailsParsedResponseBody = {
- givenName: 'John',
- surname: 'Doe',
+ firstName: 'John',
+ lastName: 'Doe',
};
// ...
//=============================
// THE CLIENT FRONT-END PROJECT
//=============================
// ...
render() {
const userDetails = this.props.userDetails;
return <section>
// 🔥🔥 BOOM 🔥🔥 <h1>undefined undefined</h1>
<h1>{userDetails.givenName + ' ' + userDetails.surname}</h1>
// ...