Open Side Menu Go to the Top
Register
Looking for Hand Evaluators (js) Looking for Hand Evaluators (js)

04-20-2019 , 05:27 AM
As a side project I'm making a browser-based poker client with a Typescript Node.js backend, and am at the point where I need to start classifying/evaluating hands.

There's a lot of stuff out there, and am looking for recommendations.

Things I value in a library:
- Intuitive API/documentation
- Speed

Have read up a bit and can see the 2p2 hand evaluator has some wrappers in various languages. Here's a javascript one I've found: https://github.com/chenosaurus/poker-evaluator

There are also these npm packages:
https://www.npmjs.com/package/latest-poker-evaluator
https://www.npmjs.com/package/pokersolver

Can anyone recommend one (preferably in JS), or comment on the above ones?
Looking for Hand Evaluators (js) Quote
11-28-2019 , 02:03 PM
I ended up using https://github.com/chenosaurus/poker-evaluator, which uses the 2p2 precomputed HandRanks.dat file, so is very performant.


I added typings to DefinitelyTyped to assist anyone else using Typescript
Looking for Hand Evaluators (js) Quote
12-04-2019 , 03:21 AM
this looks interesting, will check it out when i have some free time
Looking for Hand Evaluators (js) Quote
12-06-2019 , 12:51 AM
Depending on how you use it skpe may be faster. If you can cache 5 and 6 card holdings it is definitely faster.

I've seen it available in c and java, not js. So you'd need to port it.
Looking for Hand Evaluators (js) Quote

      
m