Skip to content

Commit 14f33cf

Browse files
nguansakvaishnav-mkfredovecinobaseballyama
authored
[docs] add rel noreferrer to fix warning in tutorial (#8024)
Co-authored-by: vaishnav <[email protected]> Co-authored-by: Alfredo Vecino <[email protected]> Co-authored-by: Yuichiro Yamashita <[email protected]>
1 parent 8b462fd commit 14f33cf

File tree

5 files changed

+9
-9
lines changed

5 files changed

+9
-9
lines changed

site/content/examples/09-transitions/06-deferred-transitions/App.svelte

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -56,8 +56,8 @@
5656
>
5757

5858
<p class='credit'>
59-
<a target="_blank" href="https://www.flickr.com/photos/{d.path}">via Flickr</a> &ndash;
60-
<a target="_blank" href={d.license.url}>{d.license.name}</a>
59+
<a target="_blank" rel="noreferrer" href="https://www.flickr.com/photos/{d.path}">via Flickr</a> &ndash;
60+
<a target="_blank" rel="noreferrer" href={d.license.url}>{d.license.name}</a>
6161
</p>
6262
</div>
6363
{/await}

site/content/examples/21-miscellaneous/01-hacker-news/Summary.svelte

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@
1313

1414
<article>
1515
<span>{i + offset + 1}</span>
16-
<h2><a target="_blank" href={url}>{item.title}</a></h2>
16+
<h2><a target="_blank" rel="noreferrer" href={url}>{item.title}</a></h2>
1717
<p class="meta"><a href="#/item/{item.id}">{comment_text()}</a> by {item.user} {item.time_ago}</p>
1818
</article>
1919

@@ -37,4 +37,4 @@
3737
a {
3838
color: #333;
3939
}
40-
</style>
40+
</style>

site/content/tutorial/04-logic/04-each-blocks/app-a/App.svelte

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@
1010

1111
<ul>
1212
<!-- open each block -->
13-
<li><a target="_blank" href="https://www.youtube.com/watch?v={cat.id}">
13+
<li><a target="_blank" href="https://www.youtube.com/watch?v={cat.id}" rel="noreferrer">
1414
{cat.name}
1515
</a></li>
1616
<!-- close each block -->

site/content/tutorial/04-logic/04-each-blocks/app-b/App.svelte

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@
1010

1111
<ul>
1212
{#each cats as { id, name }, i}
13-
<li><a target="_blank" href="https://www.youtube.com/watch?v={id}">
13+
<li><a target="_blank" href="https://www.youtube.com/watch?v={id}" rel="noreferrer">
1414
{i + 1}: {name}
1515
</a></li>
1616
{/each}

site/content/tutorial/04-logic/04-each-blocks/text.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ If you need to loop over lists of data, use an `each` block:
77
```html
88
<ul>
99
{#each cats as cat}
10-
<li><a target="_blank" href="https://www.youtube.com/watch?v={cat.id}">
10+
<li><a target="_blank" href="https://www.youtube.com/watch?v={cat.id}" rel="noreferrer">
1111
{cat.name}
1212
</a></li>
1313
{/each}
@@ -20,10 +20,10 @@ You can get the current *index* as a second argument, like so:
2020

2121
```html
2222
{#each cats as cat, i}
23-
<li><a target="_blank" href="https://www.youtube.com/watch?v={cat.id}">
23+
<li><a target="_blank" href="https://www.youtube.com/watch?v={cat.id}" rel="noreferrer">
2424
{i + 1}: {cat.name}
2525
</a></li>
2626
{/each}
2727
```
2828

29-
If you prefer, you can use destructuring — `each cats as { id, name }` — and replace `cat.id` and `cat.name` with `id` and `name`.
29+
If you prefer, you can use destructuring — `each cats as { id, name }` — and replace `cat.id` and `cat.name` with `id` and `name`.

0 commit comments

Comments
 (0)