Skip to content
This repository was archived by the owner on Dec 27, 2022. It is now read-only.

Conversation

@tylerpaige
Copy link
Contributor

In some cases, developers may want to skip image processing entirely. This may be useful for a site that is using an image CDN such as cloudinary: the CDN provides transformations, so we don't need to use Gatsby's transformation layer. This PR adds such an option.

Relevant issues: #305

In some cases, developers may want to skip image processing entirely. This may be useful for a site that is using an image CDN such as cloudinary: the cdn provides transformations, so we don't need to use Gatsby's transformation layer.
@strapi-cla
Copy link

strapi-cla commented Apr 26, 2022

CLA assistant check
All committers have signed the CLA.

@raae
Copy link

raae commented May 26, 2022

I would suggest using the term "skipFileDownloads" as the image processing is being done by other plugins on all file nodes. So it's not really skipping image processing, its skipping creating File Nodes for the images.

"skipFileDownloads" is lifted from the Drupal Plugin, the WP Plugin uses "createFileNodes".

Per feedback from @raae, this option does not actually stop images from being processed, as that would be done by other parts of the Gatsby ecosystem. Rather, this option solely prevents the downloading of media files & sourced into File Nodes.
@tylerpaige
Copy link
Contributor Author

@raae that's a great point. just submitted that change!

@tylerpaige
Copy link
Contributor Author

Hi friends,
Is there anything I can do to move this PR forward? I'm definitely interested in saving myself the build time & bandwidth costs caused by downloading these images.

Thanks!

Copy link
Contributor

@remidej remidej left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for the PR, this is a nice improvement! Just a small requested change on the readme, otherwise I think it can be shipped in the next release. Sorry for the time it took to review

}
```

If you do not want this plugin to download your media (images, videos, and file attachments), you can use the `skipFileDownloads` configuration option
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

In the PR description you say:

This may be useful for a site that is using an image CDN such as cloudinary: the CDN provides transformations, so we don't need to use Gatsby's transformation layer.

I think it would be nice to add that here to, to make it more clear why users may want to use that option. And also mention that it would reduce build times

Copy link
Contributor

@remidej remidej left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Merging this as we want to ship a release soon, and the readme can be improved later. Thanks again.

@remidej remidej merged commit 0221b44 into gatsby-uc:master Sep 6, 2022
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants