diff --git a/curriculum/challenges/english/blocks/cat-photo-app/5dc174fcf86c76b9248c6eb2.md b/curriculum/challenges/english/blocks/cat-photo-app/5dc174fcf86c76b9248c6eb2.md index 6986a0647f0..030316350bb 100644 --- a/curriculum/challenges/english/blocks/cat-photo-app/5dc174fcf86c76b9248c6eb2.md +++ b/curriculum/challenges/english/blocks/cat-photo-app/5dc174fcf86c76b9248c6eb2.md @@ -26,6 +26,12 @@ Your `h1` element should have an opening tag. Opening tags have this syntax: `/); +``` + Your `h1` element should have a closing tag. Closing tags have this syntax: ``. ```js diff --git a/curriculum/challenges/english/blocks/cat-photo-app/5dc1798ff86c76b9248c6eb3.md b/curriculum/challenges/english/blocks/cat-photo-app/5dc1798ff86c76b9248c6eb3.md index f6fff465a78..c2224442f79 100644 --- a/curriculum/challenges/english/blocks/cat-photo-app/5dc1798ff86c76b9248c6eb3.md +++ b/curriculum/challenges/english/blocks/cat-photo-app/5dc1798ff86c76b9248c6eb3.md @@ -37,6 +37,12 @@ Your `h1` element's text should be 'CatPhotoApp'. You have either omitted the te assert.equal(document.querySelector('h1')?.innerText.toLowerCase(), 'catphotoapp'); ``` +Your `h2` tags should be in lowercase. By convention, all HTML tags are written in lowercase. + +```js +assert.notMatch(code, /<\/?H2>/); +``` + Your `h2` element should have an opening tag. Opening tags have this syntax: ``. ```js diff --git a/curriculum/challenges/english/blocks/cat-photo-app/5dc17d3bf86c76b9248c6eb4.md b/curriculum/challenges/english/blocks/cat-photo-app/5dc17d3bf86c76b9248c6eb4.md index eae0ea60c5a..a1d1b5e6dcd 100644 --- a/curriculum/challenges/english/blocks/cat-photo-app/5dc17d3bf86c76b9248c6eb4.md +++ b/curriculum/challenges/english/blocks/cat-photo-app/5dc17d3bf86c76b9248c6eb4.md @@ -19,6 +19,12 @@ Your `p` element should have an opening tag. Opening tags have the following syn assert.exists(document.querySelector('p')); ``` +Your `p` tags should be in lowercase. By convention, all HTML tags are written in lowercase. + +```js +assert.notMatch(code, /<\/?P>/); +``` + Your `p` element should have a closing tag. Closing tags have a `/` just after the `<` character. ```js diff --git a/curriculum/challenges/english/blocks/learn-html-by-building-a-cat-photo-app/5dc174fcf86c76b9248c6eb2.md b/curriculum/challenges/english/blocks/learn-html-by-building-a-cat-photo-app/5dc174fcf86c76b9248c6eb2.md index 2af6314da3a..40525c0ec27 100644 --- a/curriculum/challenges/english/blocks/learn-html-by-building-a-cat-photo-app/5dc174fcf86c76b9248c6eb2.md +++ b/curriculum/challenges/english/blocks/learn-html-by-building-a-cat-photo-app/5dc174fcf86c76b9248c6eb2.md @@ -28,6 +28,12 @@ Your `h1` element should have an opening tag. Opening tags have this syntax: `/); +``` + Your `h1` element should have a closing tag. Closing tags have a `/` just after the `<` character. ```js diff --git a/curriculum/challenges/english/blocks/learn-html-by-building-a-cat-photo-app/5dc1798ff86c76b9248c6eb3.md b/curriculum/challenges/english/blocks/learn-html-by-building-a-cat-photo-app/5dc1798ff86c76b9248c6eb3.md index c5844cc0ad6..529c0f75a5c 100644 --- a/curriculum/challenges/english/blocks/learn-html-by-building-a-cat-photo-app/5dc1798ff86c76b9248c6eb3.md +++ b/curriculum/challenges/english/blocks/learn-html-by-building-a-cat-photo-app/5dc1798ff86c76b9248c6eb3.md @@ -52,6 +52,12 @@ Your `h1` element's text should be `CatPhotoApp`. You have either omitted the te assert(document.querySelector('h1').innerText.toLowerCase() === 'catphotoapp'); ``` +Your `h2` tags should be in lowercase. By convention, all HTML tags are written in lowercase. + +```js +assert.notMatch(code, /<\/?H2>/); +``` + Your `h2` element should have an opening tag. Opening tags have this syntax: ``. ```js diff --git a/curriculum/challenges/english/blocks/learn-html-by-building-a-cat-photo-app/5dc17d3bf86c76b9248c6eb4.md b/curriculum/challenges/english/blocks/learn-html-by-building-a-cat-photo-app/5dc17d3bf86c76b9248c6eb4.md index 1f5f84ef95c..d60fda13e95 100644 --- a/curriculum/challenges/english/blocks/learn-html-by-building-a-cat-photo-app/5dc17d3bf86c76b9248c6eb4.md +++ b/curriculum/challenges/english/blocks/learn-html-by-building-a-cat-photo-app/5dc17d3bf86c76b9248c6eb4.md @@ -19,6 +19,12 @@ Your `p` element should have an opening tag. Opening tags have the following syn assert(document.querySelector('p')); ``` +Your `p` tags should be in lowercase. By convention, all HTML tags are written in lowercase. + +```js +assert.notMatch(code, /<\/?P>/); +``` + Your `p` element should have a closing tag. Closing tags have a `/` just after the `<` character. ```js diff --git a/curriculum/challenges/english/blocks/learn-html-by-building-a-cat-photo-app/5dc2385ff86c76b9248c6eb7.md b/curriculum/challenges/english/blocks/learn-html-by-building-a-cat-photo-app/5dc2385ff86c76b9248c6eb7.md index d4d19ab096f..319ca1c07c0 100644 --- a/curriculum/challenges/english/blocks/learn-html-by-building-a-cat-photo-app/5dc2385ff86c76b9248c6eb7.md +++ b/curriculum/challenges/english/blocks/learn-html-by-building-a-cat-photo-app/5dc2385ff86c76b9248c6eb7.md @@ -28,6 +28,19 @@ Your `main` element should have an opening tag. Opening tags have this syntax: ` assert(document.querySelector('main')); ``` +Your `main` tags should be in lowercase. By convention, all HTML tags are written in lowercase. + +```js +const mainTagMatches = code.matchAll(/<\/?main>/gi); +for (const match of mainTagMatches) { + const tag = match[0]; + assert.strictEqual( + tag, + tag.toLowerCase() + ); +} +``` + Your `main` element should have a closing tag. Closing tags have a `/` just after the `<` character. ```js diff --git a/curriculum/challenges/english/blocks/lecture-understanding-html-attributes/66f6db08d55022680a3cfbc9.md b/curriculum/challenges/english/blocks/lecture-understanding-html-attributes/66f6db08d55022680a3cfbc9.md index 8160bb310e2..e799fe9cc78 100644 --- a/curriculum/challenges/english/blocks/lecture-understanding-html-attributes/66f6db08d55022680a3cfbc9.md +++ b/curriculum/challenges/english/blocks/lecture-understanding-html-attributes/66f6db08d55022680a3cfbc9.md @@ -13,7 +13,7 @@ HTML, which stands for Hypertext Markup Language, is a markup language for creat

Hello

``` -Most elements will have an opening tag and a closing tag. Sometimes those tags are referred to as start and end tags. In between those two tags, you will have the content. This content can be text or other HTML elements. Both opening and closing tags start with a left angle bracket (`<`), and end with a right angle bracket (`>`), with the tag name placed between these angle brackets. Here is a closer look at just the opening and closing paragraph tags: +Most elements will have an opening tag and a closing tag. Sometimes those tags are referred to as start and end tags. In between those two tags, you will have the content. This content can be text or other HTML elements. Both opening and closing tags start with a left angle bracket (`<`), and end with a right angle bracket (`>`), with the tag name placed between these angle brackets. While HTML tag names are case-insensitive, it is a widely accepted convention and best practice to write them in lowercase. Here is a closer look at just the opening and closing paragraph tags: ```html

diff --git a/curriculum/challenges/english/blocks/workshop-cat-photo-app/5dc174fcf86c76b9248c6eb2.md b/curriculum/challenges/english/blocks/workshop-cat-photo-app/5dc174fcf86c76b9248c6eb2.md index ba7f1824c1b..01084bf8213 100644 --- a/curriculum/challenges/english/blocks/workshop-cat-photo-app/5dc174fcf86c76b9248c6eb2.md +++ b/curriculum/challenges/english/blocks/workshop-cat-photo-app/5dc174fcf86c76b9248c6eb2.md @@ -26,6 +26,12 @@ Your `h1` element should have an opening tag. Opening tags have this syntax: `/); +``` + Your `h1` element should have a closing tag. Closing tags have this syntax: ``. ```js diff --git a/curriculum/challenges/english/blocks/workshop-cat-photo-app/5dc1798ff86c76b9248c6eb3.md b/curriculum/challenges/english/blocks/workshop-cat-photo-app/5dc1798ff86c76b9248c6eb3.md index 623ebd4fe24..763738674ce 100644 --- a/curriculum/challenges/english/blocks/workshop-cat-photo-app/5dc1798ff86c76b9248c6eb3.md +++ b/curriculum/challenges/english/blocks/workshop-cat-photo-app/5dc1798ff86c76b9248c6eb3.md @@ -37,6 +37,12 @@ Your `h1` element's text should be 'CatPhotoApp'. You have either omitted the te assert.equal(document.querySelector('h1')?.innerText?.trim().toLowerCase(), 'catphotoapp'); ``` +Your `h2` tags should be in lowercase. By convention, all HTML tags are written in lowercase. + +```js +assert.notMatch(code, /<\/?H2>/); +``` + Your `h2` element should have an opening tag. Opening tags have this syntax: ``. ```js diff --git a/curriculum/challenges/english/blocks/workshop-cat-photo-app/5dc17d3bf86c76b9248c6eb4.md b/curriculum/challenges/english/blocks/workshop-cat-photo-app/5dc17d3bf86c76b9248c6eb4.md index 8291b9cc641..b226f4d3c10 100644 --- a/curriculum/challenges/english/blocks/workshop-cat-photo-app/5dc17d3bf86c76b9248c6eb4.md +++ b/curriculum/challenges/english/blocks/workshop-cat-photo-app/5dc17d3bf86c76b9248c6eb4.md @@ -19,6 +19,12 @@ Your `p` element should have an opening tag. Opening tags have the following syn assert.exists(document.querySelector('p')); ``` +Your `p` tags should be in lowercase. By convention, all HTML tags are written in lowercase. + +```js +assert.notMatch(code, /<\/?P>/); +``` + Your `p` element should have a closing tag. Closing tags have a `/` just after the `<` character. ```js diff --git a/curriculum/challenges/english/blocks/workshop-cat-photo-app/5dc2385ff86c76b9248c6eb7.md b/curriculum/challenges/english/blocks/workshop-cat-photo-app/5dc2385ff86c76b9248c6eb7.md index 6b1b5fb29cc..bd264602bd9 100644 --- a/curriculum/challenges/english/blocks/workshop-cat-photo-app/5dc2385ff86c76b9248c6eb7.md +++ b/curriculum/challenges/english/blocks/workshop-cat-photo-app/5dc2385ff86c76b9248c6eb7.md @@ -28,6 +28,19 @@ Your `main` element should have an opening tag. Opening tags have this syntax: ` assert.exists(document.querySelector('main')); ``` +Your `main` tags should be in lowercase. By convention, all HTML tags are written in lowercase. + +```js +const mainTagMatches = code.matchAll(/<\/?main>/gi); +for (const match of mainTagMatches) { + const tag = match[0] + assert.strictEqual( + tag, + tag.toLowerCase() + ); +} +``` + Your `main` element should have a closing tag. Closing tags have a `/` just after the `<` character. ```js