Skip to content
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

crush() doesn't handle dots in property names well #365

Open
stefaanMLB opened this issue Nov 29, 2023 · 3 comments
Open

crush() doesn't handle dots in property names well #365

stefaanMLB opened this issue Nov 29, 2023 · 3 comments

Comments

@stefaanMLB
Copy link

import { crush } from 'radash';
const test = {
  prop1: 'value1',
  'prop2.sub1': 'value2',
  prop3: {
    prop4: 'value4',
    'prop5.sub2': 'value5'
  }
};
console.log(crush(test));

outputs

{
  prop1: 'value1',
  'prop2.sub1': undefined,
  'prop3.prop4': 'value4',
  'prop3.prop5.sub2': undefined
}

Whenever there is a dot in a proptery name, the value is undefined.
Even is I'm pushing the limits by having the dots in the property names, these's still no reason for the values to be undefined

@Balvajs
Copy link

Balvajs commented Mar 6, 2024

+1 for this issue.
@stefaanv I see you had a PR for this, but it got closed. Was it not working?

@stefaanMLB
Copy link
Author

@Balvajs no, the repo seems to have been abandonned, unfortunately.
A shame really because it's a really good initiative.

@Balvajs
Copy link

Balvajs commented Mar 7, 2024

@stefaanMLB oh no 😕
Do you know if there is some statement somewhere or more info about abandoning this repo?
2 weeks ago the author made a release, so maybe he could be back 🤞

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants