-
Notifications
You must be signed in to change notification settings - Fork 18
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
da9eb37
commit bd7e0b5
Showing
7 changed files
with
86 additions
and
90 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,30 @@ | ||
import { getCldImageUrl } from 'next-cloudinary'; | ||
|
||
import images from '../../data/images.json'; | ||
|
||
# CDN Images | ||
|
||
Images that are being sourced from an external CDN. | ||
|
||
export const Grid = () => { | ||
return ( | ||
<ul className="grid grid-cols-2 lg:grid-cols-3 gap-6 my-8"> | ||
{images.map((image) => { | ||
return ( | ||
<li key={image.src}> | ||
<img | ||
src={image.srcCdn} | ||
width={image.width} | ||
height={image.height} | ||
alt={image.title} | ||
/> | ||
</li> | ||
); | ||
})} | ||
</ul> | ||
) | ||
} | ||
|
||
## Demo | ||
|
||
<Grid /> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,32 @@ | ||
import { getCldImageUrl } from 'next-cloudinary'; | ||
|
||
import images from '../../data/images.json'; | ||
|
||
# Cloudinary Images | ||
|
||
Images already being delivered from Cloudinary will not be replaced. | ||
|
||
export const Grid = () => { | ||
return ( | ||
<ul className="grid grid-cols-2 lg:grid-cols-3 gap-6 my-8"> | ||
{images.map((image) => { | ||
return ( | ||
<li key={image.src}> | ||
<img | ||
src={getCldImageUrl({ | ||
src: image.srcCloudinary | ||
})} | ||
width={image.width} | ||
height={image.height} | ||
alt={image.title} | ||
/> | ||
</li> | ||
); | ||
})} | ||
</ul> | ||
) | ||
} | ||
|
||
## Demo | ||
|
||
<Grid /> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters