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

Randomly length for toCollection generator #304

Open
wants to merge 2 commits into
base: main
Choose a base branch
from

Conversation

manudss
Copy link
Contributor

@manudss manudss commented Aug 17, 2022

PR Checklist

Please check if your PR fulfills the following requirements:

PR Type

What kind of change does this PR introduce?

[ ] Bugfix
[x] Feature
[ ] Code style update (formatting, local variables)
[ ] Refactoring (no functional changes, no api changes)
[ ] Build related changes
[ ] CI related changes
[x] Documentation content changes
[ ] Other... Please describe:

What is the current behavior?

toCollection function will return the length specified number of items.

Issue Number: 303

What is the new behavior?

Add some new parameters, minLength and maxLength. If one or both are specified, toCollection Function will generate a random list of item (from minLength and maxLength).

Does this PR introduce a breaking change?

[ ] Yes
[x] No

Other information

You can specify minLength or maxLength (or both), to generate a random length collection.
If one of minLength or maxLength is specified, a random length will be calculated before,
 and will return this random number of items.

fix ngneat#303
@manudss manudss changed the title Feature/#303 remdomly length to collection generator Feature/#303 randomly length for toCollection generator Aug 17, 2022
@manudss manudss changed the title Feature/#303 randomly length for toCollection generator Randomly length for toCollection generator Aug 17, 2022
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.

1 participant