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

extend get function to handle path contain quote #336

Merged
merged 3 commits into from
Feb 21, 2024
Merged

extend get function to handle path contain quote #336

merged 3 commits into from
Feb 21, 2024

Conversation

xiamibuchi
Copy link
Contributor

Description

For the get method, the case where the path contains quotation marks is not handled

for example:

const obj = {
    num: 1
}
get(obj, '["num"]')

Checklist

  • Changes are covered by tests if behavior has been changed or added
  • Tests have 100% coverage
  • If code changes were made, the version in package.json has been bumped (matching semver)
  • If code changes were made, the yarn build command has been run and to update the cdn directory
  • If code changes were made, the documentation (in the /docs directory) has been updated

Resolves

If the PR resolves an open issue tag it here. For example, Resolves #34

@vercel
Copy link

vercel bot commented Aug 1, 2023

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Comments Updated (UTC)
radash-docs ✅ Ready (Inspect) Visit Preview 💬 Add feedback Feb 21, 2024 2:41am

Copy link
Owner

@sodiray sodiray left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I made one small change to keep the key variable as a const but otherwise love it, merging! Thanks @xiamibuchi 🙏

@sodiray sodiray merged commit 2d6c10a into sodiray:master Feb 21, 2024
4 of 8 checks passed
@xiamibuchi xiamibuchi deleted the extend-get-function-for-path-contain-quote branch February 22, 2024 08:34
aleclarson referenced this pull request in radashi-org/radashi Jun 24, 2024
* extend get function to handle path contain quote

* Use const instead of updating key value

---------

Co-authored-by: shenyang <shenyang@xd.com>
Co-authored-by: Ray Epps <rayharryepps@gmail.com>
Co-authored-by: Ray Epps <ray@unishine.dev>
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

Successfully merging this pull request may close these issues.

None yet

2 participants