Skip to content

Commit

Permalink
Open deploy link in new window for examples (#40804)
Browse files Browse the repository at this point in the history
Let's open the deploy link in a new window so the link isn't blocked
when running an an iframe, such as Stackblitz.

Previously, this would print the following error:

> Refused to display 'https://vercel.com/' in a frame because it set
'X-Frame-Options' to 'deny'
  • Loading branch information
styfle committed Sep 22, 2022
1 parent 48292ba commit be904d7
Show file tree
Hide file tree
Showing 15 changed files with 30 additions and 0 deletions.
2 changes: 2 additions & 0 deletions examples/progressive-web-app/pages/index.tsx
Expand Up @@ -34,6 +34,8 @@ export default function Home() {

<a
href="https://vercel.com/new?utm_source=create-next-app&utm_medium=default-template&utm_campaign=create-next-app"
target="_blank"
rel="noopener noreferrer"
className={styles.card}
>
<h3>Deploy &rarr;</h3>
Expand Down
2 changes: 2 additions & 0 deletions examples/with-cypress/pages/index.tsx
Expand Up @@ -50,6 +50,8 @@ export default function Home() {

<a
href="https://vercel.com/new?utm_source=create-next-app&utm_medium=default-template&utm_campaign=create-next-app"
target="_blank"
rel="noopener noreferrer"
className={styles.card}
>
<h2>Deploy &rarr;</h2>
Expand Down
2 changes: 2 additions & 0 deletions examples/with-docker-compose/next-app/src/pages/index.tsx
Expand Up @@ -41,6 +41,8 @@ export default function Home() {

<a
href="https://vercel.com/new?utm_source=create-next-app&utm_medium=default-template&utm_campaign=create-next-app"
target="_blank"
rel="noopener noreferrer"
className={styles.card}
>
<h3>Deploy &rarr;</h3>
Expand Down
2 changes: 2 additions & 0 deletions examples/with-docker-multi-env/pages/index.js
Expand Up @@ -41,6 +41,8 @@ export default function Home() {

<a
href="https://vercel.com/new?utm_source=create-next-app&utm_medium=default-template&utm_campaign=create-next-app"
target="_blank"
rel="noopener noreferrer"
className={styles.card}
>
<h3>Deploy &rarr;</h3>
Expand Down
2 changes: 2 additions & 0 deletions examples/with-docker/pages/index.js
Expand Up @@ -40,6 +40,8 @@ export default function Home() {

<a
href="https://vercel.com/new?utm_source=create-next-app&utm_medium=default-template&utm_campaign=create-next-app"
target="_blank"
rel="noopener noreferrer"
className={styles.card}
>
<h3>Deploy &rarr;</h3>
Expand Down
2 changes: 2 additions & 0 deletions examples/with-elasticsearch/pages/index.js
Expand Up @@ -52,6 +52,8 @@ export default function Home({ isConnected }) {

<a
href="https://vercel.com/new?utm_source=create-next-app&utm_medium=default-template&utm_campaign=create-next-app"
target="_blank"
rel="noopener noreferrer"
className={styles.card}
>
<h2>Deploy &rarr;</h2>
Expand Down
2 changes: 2 additions & 0 deletions examples/with-graphql-gateway/pages/index.tsx
Expand Up @@ -43,6 +43,8 @@ const Home: NextPage = () => {

<a
href="https://vercel.com/new?utm_source=create-next-app&utm_medium=default-template&utm_campaign=create-next-app"
target="_blank"
rel="noopener noreferrer"
className={styles.card}
>
<h2>Deploy &rarr;</h2>
Expand Down
2 changes: 2 additions & 0 deletions examples/with-knex/pages/index.js
Expand Up @@ -60,6 +60,8 @@ export default function Home() {

<a
href="https://vercel.com/new?utm_source=create-next-app&utm_medium=default-template&utm_campaign=create-next-app"
target="_blank"
rel="noopener noreferrer"
className="card"
>
<h3>Deploy &rarr;</h3>
Expand Down
2 changes: 2 additions & 0 deletions examples/with-mongodb/pages/index.tsx
Expand Up @@ -74,6 +74,8 @@ export default function Home({

<a
href="https://vercel.com/new?utm_source=create-next-app&utm_medium=default-template&utm_campaign=create-next-app"
target="_blank"
rel="noopener noreferrer"
className="card"
>
<h3>Deploy &rarr;</h3>
Expand Down
2 changes: 2 additions & 0 deletions examples/with-particles/pages/index.tsx
Expand Up @@ -45,6 +45,8 @@ const Home: NextPage = () => {

<a
href="https://vercel.com/new?utm_source=create-next-app&utm_medium=default-template&utm_campaign=create-next-app"
target="_blank"
rel="noopener noreferrer"
className={styles.card}
>
<h2>Deploy &rarr;</h2>
Expand Down
2 changes: 2 additions & 0 deletions examples/with-playwright/pages/index.js
Expand Up @@ -50,6 +50,8 @@ export default function Home() {

<a
href="https://vercel.com/new?utm_source=create-next-app&utm_medium=default-template&utm_campaign=create-next-app"
target="_blank"
rel="noopener noreferrer"
className={styles.card}
>
<h2>Deploy &rarr;</h2>
Expand Down
2 changes: 2 additions & 0 deletions examples/with-sitemap/pages/index.js
Expand Up @@ -38,6 +38,8 @@ export default function Home() {

<a
href="https://vercel.com/new?utm_source=create-next-app&utm_medium=default-template&utm_campaign=create-next-app"
target="_blank"
rel="noopener noreferrer"
className="card"
>
<h3>Deploy &rarr;</h3>
Expand Down
2 changes: 2 additions & 0 deletions examples/with-vitest/pages/index.tsx
Expand Up @@ -43,6 +43,8 @@ const Home: NextPage = () => {

<a
href="https://vercel.com/new?utm_source=create-next-app&utm_medium=default-template&utm_campaign=create-next-app"
target="_blank"
rel="noopener noreferrer"
className={styles.card}
>
<h2>Deploy &rarr;</h2>
Expand Down
2 changes: 2 additions & 0 deletions packages/create-next-app/templates/default/pages/index.js
Expand Up @@ -42,6 +42,8 @@ export default function Home() {

<a
href="https://vercel.com/new?utm_source=create-next-app&utm_medium=default-template&utm_campaign=create-next-app"
target="_blank"
rel="noopener noreferrer"
className={styles.card}
>
<h2>Deploy &rarr;</h2>
Expand Down
2 changes: 2 additions & 0 deletions packages/create-next-app/templates/typescript/pages/index.tsx
Expand Up @@ -43,6 +43,8 @@ const Home: NextPage = () => {

<a
href="https://vercel.com/new?utm_source=create-next-app&utm_medium=default-template&utm_campaign=create-next-app"
target="_blank"
rel="noopener noreferrer"
className={styles.card}
>
<h2>Deploy &rarr;</h2>
Expand Down

0 comments on commit be904d7

Please sign in to comment.