Skip to content

Commit 74e1b96

Browse files
fix: add src type to CloudinaryLoaderCldOptions interface (#552)
# Description This PR will add the `src` type to `CloudinaryLoaderCldOptions` interface to fix the ts error being thrown from the `cloudinary-loader.ts` file. Fixes This will close #425 <!-- Specify above which issue this fixes by referencing the issue number (`#<ISSUE_NUMBER>`) or issue URL. --> <!-- Example: Fixes https://github.com/cloudinary-community/next-cloudinary/issues/<ISSUE_NUMBER> --> ## Type of change <!-- Please select all options that are applicable. --> - [x] Bug fix (non-breaking change which fixes an issue) - [ ] New feature (non-breaking change which adds functionality) - [ ] Breaking change (fix or feature that would cause existing functionality to not work as expected) - [ ] Fix or improve the documentation - [ ] This change requires a documentation update # Checklist <!-- These must all be followed and checked. --> - [x] I have followed the contributing guidelines of this project as mentioned in [CONTRIBUTING.md](/CONTRIBUTING.md) - [x] I have created an [issue](https://github.com/cloudinary-community/next-cloudinary/issues) ticket for this PR - [x] I have checked to ensure there aren't other open [Pull Requests](https://github.com/cloudinary-community/next-cloudinary/pulls) for the same update/change? - [x] I have performed a self-review of my own code - [x] I have run tests locally to ensure they all pass - [x] I have commented my code, particularly in hard-to-understand areas - [x] I have made corresponding changes needed to the documentation --------- Co-authored-by: Colby Fayock <[email protected]>
1 parent 2955336 commit 74e1b96

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

next-cloudinary/src/loaders/cloudinary-loader.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,7 @@ import { ImageProps } from 'next/image';
33
import { getCldImageUrl } from '../helpers/getCldImageUrl';
44

55
export interface CloudinaryLoaderCldOptions {
6+
src: string
67
}
78

89
export interface CloudinaryLoaderLoaderOptions {
@@ -53,6 +54,5 @@ export function cloudinaryLoader({ loaderOptions, imageProps, cldOptions, cldCon
5354
options.width = loaderOptions?.width;
5455
}
5556

56-
// @ts-ignore
5757
return getCldImageUrl(options, cldConfig);
5858
}

0 commit comments

Comments
 (0)