Skip to content

Commit

Permalink
Fix original defaultProp object getting mutated
Browse files Browse the repository at this point in the history
  • Loading branch information
masiulis committed Jul 30, 2024
1 parent 41ac730 commit 2d6c583
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/ReactSpreadsheetImport.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ export const defaultRSIProps: Partial<RsiProps<any>> = {
} as const

export const ReactSpreadsheetImport = <T extends string>(propsWithoutDefaults: RsiProps<T>) => {
const props = merge(defaultRSIProps, propsWithoutDefaults)
const props = merge({}, defaultRSIProps, propsWithoutDefaults)
const mergedTranslations =
props.translations !== translations ? merge(translations, props.translations) : translations
const mergedThemes = props.rtl
Expand Down

0 comments on commit 2d6c583

Please sign in to comment.