Socket
Socket
Sign inDemoInstall

@uppy/react

Package Overview
Dependencies
Maintainers
5
Versions
112
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@uppy/react - npm Package Compare versions

Comparing version 4.0.0 to 4.0.1

6

lib/nonHtmlPropsHaveChanged.js

@@ -0,3 +1,7 @@

import getHTMLProps from "./getHTMLProps.js";
export default function nonHtmlPropsHaveChanged(props, prevProps) {
return Object.keys(props).some(key => !Object.hasOwn(props, key) && props[key] !== prevProps[key]);
// todo instead rewrite the components that use nonHtmlPropsHaveChanged
// to hooks, so we can use useEffect on specific props instead of this hack
const htmlProps = getHTMLProps(props);
return Object.keys(props).some(key => !Object.hasOwn(htmlProps, key) && props[key] !== prevProps[key]);
}

8

package.json
{
"name": "@uppy/react",
"description": "React component wrappers around Uppy's official UI plugins.",
"version": "4.0.0",
"version": "4.0.1",
"license": "MIT",

@@ -36,5 +36,5 @@ "main": "lib/index.js",

"peerDependencies": {
"@uppy/core": "^4.0.0",
"@uppy/dashboard": "^4.0.0",
"@uppy/drag-drop": "^4.0.0",
"@uppy/core": "^4.0.1",
"@uppy/dashboard": "^4.0.1",
"@uppy/drag-drop": "^4.0.1",
"@uppy/file-input": "^4.0.0",

@@ -41,0 +41,0 @@ "@uppy/progress-bar": "^4.0.0",

@@ -0,7 +1,12 @@

import getHTMLProps from './getHTMLProps.ts'
export default function nonHtmlPropsHaveChanged<
T extends Record<string, unknown>,
>(props: T, prevProps: T): boolean {
// todo instead rewrite the components that use nonHtmlPropsHaveChanged
// to hooks, so we can use useEffect on specific props instead of this hack
const htmlProps = getHTMLProps(props)
return Object.keys(props).some(
(key) => !Object.hasOwn(props, key) && props[key] !== prevProps[key],
(key) => !Object.hasOwn(htmlProps, key) && props[key] !== prevProps[key],
)
}

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc