<section class="usage-guides">

# Cardrinal naming strategy for Assets, Web Components and Angular Components

<hr> 

## Overview

What is this section? How can this help you...

We build agnostic web components for Transamerica with Angular's custome web components package, Elements. Since transamerica is an Angular shop, we also develop traditional Angular components for consumption. We also provide styles and other overall development tools and direction for teams.

These various offerings can provide difficulty in differenciating type and use. To provide clarification, we have developed a few naming rules to differenciate our offerings.

**Note:** Be aware of these differences when consuming Cardinal and contributing work.

### Web Components (Angular Elements)

<hr class="ta-shortDivider">

"Angular elements are Angular components packaged as custom elements (also called Web Components), a web standard for defining new HTML elements in a framework-agnostic way."

To learn more about Angular Elements, check out thier [overview page](https://angular.io/guide/elements)
To learn more about Custom Elements, check out the MDN web docs on [using custom elements](https://developer.mozilla.org/en-US/docs/Web/Web_Components/Using_custom_elements).

To differentiate an Angular Element Component developed by Cardinal, we use the prefix with `ta-`. Using only the `ta-<component>` prefix tells us and our users that it is a true agnositc custom web component. For example, the element sytax to use a Cardinal button agnostic web component is `<ta-button></ta-button>`. Any other type of component or style will utilize a differentiator describing its purpose.

### Angular Components (Traditional)

<hr class="ta-shortDivider">

To learn more about Angular components, check out thier [Introduction to components](https://angular.io/guide/architecture-components
) documentation.

To learn more about Custom Elements, check out the MDN web docs on [using custom elements](https://developer.mozilla.org/en-US/docs/Web/Web_Components/Using_custom_elements).

To differentiate an Angular Element Component developed by Cardinal, we use the prefix `ta-`, with a diffrentiator or `-ng`. Using the diffrentiator provides a clear visual understanding that the `ta-ng-<component>` is a tradintional Angular component. For example, the element sytax to use a Cardinal button Angular component is `<ta-ng-button></ta-ng-button>`. Any other type of component or style will utilize a differentiator describing its purpose.

### Icons

<hr class="ta-shortDivider">

Cardinal icons can be used just about anywhere. Icons utilize the `i` tag and for more semantically correct approaches, utilizing the `ta-icon` in a `<span>` tag also works.

All icons require the prefix `ta-` infront of the icon's name, as well as `-icon` preceding the icon's name. for example a search icon will be utilized as `<i class="ta-search-icon"></i>`, or `<span class="ta-icon ta-search-icon"></span>`. For more inforation on utilizing icons check our the [iconography developer reference](/iconography/developer-reference) page. For more on available icons, check out our full [icons library](/iconography/library).

</section>
