---
id: bad87fee1348bd9aedf0887a
title: Headline with the h2 Element
challengeType: 0
videoUrl: ''
localeTitle: Titular con el elemento h2
---
## Description
En las próximas lecciones, construiremos una aplicación web de fotos de gatos HTML5 pieza por pieza. El elemento h2
que agregará en este paso agregará un encabezado de nivel dos a la página web. Este elemento le dice al navegador acerca de la estructura de su sitio web. h1
elementos h1
se usan a menudo para los encabezados principales, mientras que los elementos h2
se usan generalmente para los subtítulos. También hay elementos h3
, h4
, h5
y h6
para indicar diferentes niveles de subtítulos.
## Instructions
Agregue una etiqueta h2
que diga "CatPhotoApp" para crear un segundo element
HTML debajo de su elemento h1
"Hello World".
## Tests
```yml
tests:
- text: Crear un elemento h2
.
testString: 'assert(($("h2").length > 0), "Create an h2
element.");'
- text: Asegúrese de que su elemento h2
tiene una etiqueta de cierre.
testString: 'assert(code.match(/<\/h2>/g) && code.match(/<\/h2>/g).length === code.match(//g).length, "Make sure your h2
element has a closing tag.");'
- text: Su elemento h2
debe tener el texto "CatPhotoApp".
testString: 'assert.isTrue((/cat(\s)?photo(\s)?app/gi).test($("h2").text()), "Your h2
element should have the text "CatPhotoApp".");'
- text: Su elemento h1
debe tener el texto "Hola mundo".
testString: 'assert.isTrue((/hello(\s)+world/gi).test($("h1").text()), "Your h1
element should have the text "Hello World".");'
```
## Challenge Seed
## Solution
```js
// solution required
```