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

remove empty arrays/strings #14

Open
nickersd opened this issue Mar 27, 2019 · 0 comments
Open

remove empty arrays/strings #14

nickersd opened this issue Mar 27, 2019 · 0 comments

Comments

@nickersd
Copy link

nickersd commented Mar 27, 2019

I understand that the dynamoDB does not allow empty strings or arrays of zero length. Perhaps this lib could remove elements that are empty/null/zero length.

The reason that I'm asking is that I'm using typescript, one of the the beauties of which is interfaces. So my interface requires an attribute even if empty. So currently I have to either not use an interface, not use this lib, or roll up my sleeves and pitch in:)

..although, there would be no way to unwrap into an object that conformed to the interface so the user would have to know that. I found the following stackoverflow discussion and I'm just using a recursive clean function to remove them for now and it's working great.

remove null attribs

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

1 participant