-
Notifications
You must be signed in to change notification settings - Fork 8
Fix lodash.clonedeep module issue and add module key to package.json #429
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Fix lodash.clonedeep module issue and add module key to package.json #429
Conversation
- Copy lodash.clonedeep to a file instead of importing it - Add a module key to package.json - Fix various linting issues (Delete unused lines, add missing return types)
@@ -33,16 +31,6 @@ class CloudinaryConfig { | |||
return this; | |||
} | |||
|
|||
setAPIConfig(apiConfig: IApiConfig): this { | |||
// placeholder |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This was added as a placeholder but was never used.
@@ -11,5 +11,6 @@ | |||
}, | |||
"main": "./bundles/umd/base.js", | |||
"browser": "./index.js", | |||
"module": "./index.js", |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Module is used by some build tools instead of main to correctly infer where the ESM code lives.
* _.isObjectLike(null); | ||
* // => false | ||
*/ | ||
function isObjectLike(value) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Seeing as we already have an isObject function, and this file includes an isObject and this util and others, maybe we should move such functions to their own file and import here.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We could but I wouldn't change this specific file, as it's an exact copy of lodash (we could potentially introduce new bugs by changing the implementation.
what do you think?
Pull request for @cloudinary/url-gen
What does this PR solve?
... A few words
Final checklist