Regular Expressions are everywhere, from software development to mobile applications, and being familiar with it can be of great use if you work with programming or data analysis.

Credit: Background image by Lorenzo Cafaro from Pixabay.

Before we actually start, if you don’t know exactly what regular expressions are, here is a quick intro (from Wikipedia):

If you work with websites, apps, or development of any kind of software…


One of the most difficult things in software development is: naming things. This includes variables, functions, classes, and of course, components.

To handle this problem accordingly, especially if you work in a team, nothing like a pattern to help us make things more consistent and easier.

In my team, we've created a pattern for helping us naming UI components, we call it CEV. I know, not so pretty, but works for us. 😄

The CEV pattern

CEV stands for Context, Element, and Variant. We call each of these a token of the component's name.

An example of component name with CEV naming convention (Article Card Large, respectively Context, Element and Variant).
An example of component name with CEV naming convention (Article Card Large, respectively Context, Element and Variant).
An example of a component name with the CEV naming convention.

Take a look at each one in detail, and…

André Ferraz

A web developer from Belo Horizonte, Brazil

Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store