-
-
Notifications
You must be signed in to change notification settings - Fork 160
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
Checklist: exercises that could be implemented #238
Comments
created PR #297 for word-search |
Added a new Exercise per issue exercism#238
Added a new Exercise per issue exercism#238
Address issue exercism#238
Address issue exercism#238
created PR #305 for Resistor-color-duo |
Address issue exercism#238
Address issue exercism#238
* Add exercise resistor color Address issue #238 * Add entry for resitor color in config.json * Sync this exercise Co-authored-by: rjossy <[email protected]> Co-authored-by: Derk-Jan Karrenbeld <[email protected]>
In reference to the react exercise, I wonder whether the following tests would be taking too many liberties with the canonical problem specification:
|
It's a lot like react hooks; I like how it looks. I think it's fine to do the implementation like that @peerreynders . Are you up for implementing that exercise? |
I was giving it a go. I've got the tests and the example implementation and was in the process of double checking the tests against the problem specification. That is when I noticed that the "comments" (specifications) were a lot more detailed than the exercise's readme - for example:
My The main differences are:
|
This may help a bit. The original exercise canonical data was based on these four implementations: https://github.com/exercism/nim/blob/master/exercises/react/test_react.nim It's perfectly fine if the functions and objects are composed differently (aka, it's fine if It's also okay to make the executive decision to divert from the canonical data (I can make that decision), if it suits our language better.
I somewhat agree with this, but in actuality, many reactive system output "distinct" events only. It's a choice, I suppose.
We might be able to get an answer why it was decided to implement it as distinct events. @petertseng without asking you to go back and dig deep; perhaps you recall why the exercise was implemented and canonicalised as it currently still is? @peerreynders FWIW: I had a hard time completing the JavaScript exercise because of this unexpected behaviour. I also expect events to always be "propagated", regardless of the distinctness. |
(sidenote: I think this way of implementing is fine, and after some consensus / more information, we can just go ahead and do it IMO). |
Sorry, it seems I don't know the answer to that particular question - the exercise predates me. The earliest implementation is exercism/go#170, at which point the test was already present at https://github.com/exercism/go/pull/170/files#diff-fbee2dfe4416638f307806cda10cdd55eed82a650aa4518315e8a92e693f954eR108-R110. Though I would eventually go on to canonicalise it that way, I had not been considering alternative choices when canonicalising it. |
Depending on the language being used establishing value equality in the presence of generics (parameterized types) can be tricky. It's not a problem with languages like Rust with That is why the example implementation uses the signature: function createComputed<T>(
fn: ComputeFn<T>,
value?: T,
equal?: boolean | EqualFn<T>,
options?: { name?: string }
): GetterFn<T>
const defaultEqual = <T>(lhs: T, rhs: T): boolean => lhs === rhs; being used (and still |
@petertseng thank you. @peerreynders yes I saw that; feels like |
https://tracks.exercism.io/typescript/main/unimplemented
The text was updated successfully, but these errors were encountered: