Reusing code between components in React

Composition Composition in React is the action of using components as building blocks for other components using the techniques of “containment” or “specialization”. Containment Containment is all about creating “empty spots” in a component for any random component to fill.You... View Article
Eric Njanga Dec 29, 2017

Sharing state between two or more components in React

Lifting state up In React, sharing state between components can only be done by moving it up to the closest common ancestor of the components that need it. We call it “lifting state up”. Lifting state involves writing more “boilerplate” code than two-way binding... View Article
Eric Njanga Dec 28, 2017

CSS Grid and website prototyping

CSS Grid can be used as a website prototyping tool. Supposing we’d like to try a couple of arrangement possibilities for a layout, CSS Grid is an excellent choice and we’ll see why! Using Named Areas CSS Grid “Named Areas”... View Article
Eric Njanga Dec 27, 2017

Lorsque la confience vous quitte

Les ressentiments C’est une cruelle sensation que de perdre confience en soit! La moindre chose vous intimide ou vous inquiète. Vous vous imaginez des menaces qui n’existent même pas. Des propos parfois innocent à votre égard vous donnent l’air d’être des... View Article
Eric Njanga Dec 25, 2017

Controlled Components

Let’s look at a controlled component as a tool in another component’s hand. Such a component have no “state” on its own and exists solely for the purpose of facilitating the application’s flow, for instance: A component which receives its... View Article
Eric Njanga Dec 21, 2017

Canadian Government Startup Initiative

The Canadian government just recently launched a program aimed at modernizing its digital services. The rise of tech giants and their disruptive impact on the Canadian way of life (shopping, information consumption, entertainment, …) has pushed the government into seriously considering migrating... View Article
Eric Njanga Dec 16, 2017

React Component Lifecycle

Mounting React Refers to a set of methods that are called when an instance of a component is being inserted into the DOM. These methods are: constructor componentWillMount render componentDidMount Unmounting React Refers to the method which is called when... View Article
Eric Njanga Dec 14, 2017

Box-sizing and why it matters

An understanding of box-sizing is of tremendous importance when building stable and solid responsive layouts. Box-sizing is part of the box-model CSS module, it dictates how the browser should render box elements. Box-sizing is connected to four CSS properties: width... View Article
Eric Njanga Dec 02, 2017

La ville étrangère

Peut être que tout ces rêves ne sont que des illusions Peut être ne devrais-je que me contenter de ces idées et images qui fusent dans ma tête sans cesse comme un troupeau de buffle traversant la savane au galop Peut... View Article
Eric Njanga Dec 01, 2017