ndsvw / ndsvw/Fluent-Random-Picker

Consider extension methods

Open
#6 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

help wanted idea
Dominant language
C#
Stars
40
Forks
2
Avg merge
2d 17h
Merged PRs (30d)
2

Description

  • How much effort is it?
  • is it worth it?
  • does the project name "Fluent-Random-Picker" still make sense?
    • Can extension methods for all this be built without fluent syntax?
    • Does the extension method syntax still look like the code that already exists?

Extension methods could exist for IEnumerable:

new List<int>{ 1, 2, 3}.PickOne(); // but where can you set the RNG?
new List<int>{ 1, 2, 3}.PickOne().WithSettings(rng).Evaluate(); // but then, the PickOne() logic is different to the PickOne() from the normal syntax

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by reviewing the existing PickOne fluent syntax and comparing it with the proposed IEnumerable extension examples. Determine whether RNG configuration, WithSettings, and Evaluate can remain consistent; done means a documented decision on the extension-method design and whether the project name still fits.

Written by the indexing model from the issue text.

Assessment

Tech stack
csharp
Domain
tooling
Issue type
Feature
Difficulty
5/5
Estimated time
Over a week
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
25/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.