www.digitalmars.com         C & C++   DMDScript  

digitalmars.D.announce - reduxed - Redux for D

reply Robert burner Schadek <rburners gmail.com> writes:
After working some with Angular and ngrx/store I really came to 
like the redux pattern.
Unfortunately, I couldn't find a package on code.dlang.org that 
filled that spot when coming back to D.
So I build my own.

It is called reduxed.
If you're interested you can find reduxed here 
https://code.dlang.org/packages/reduxed and 
https://github.com/burner/reduxed.

It is still rough around the corners and 
https://issues.dlang.org/show_bug.cgi?id=19084 gives me somewhat 
of a hard time, but give it try and scream at me because it is 
not nogc.
Aug 23 2018
next sibling parent visitor <visitor gmail.com> writes:
On Thursday, 23 August 2018 at 19:48:19 UTC, Robert burner 
Schadek wrote:
 After working some with Angular and ngrx/store I really came to 
 like the redux pattern.
 Unfortunately, I couldn't find a package on code.dlang.org that 
 filled that spot when coming back to D.
 So I build my own.

 It is called reduxed.
 If you're interested you can find reduxed here 
 https://code.dlang.org/packages/reduxed and 
 https://github.com/burner/reduxed.

 It is still rough around the corners and 
 https://issues.dlang.org/show_bug.cgi?id=19084 gives me 
 somewhat of a hard time, but give it try and scream at me 
 because it is not nogc.
Thank you :) as for the hard timer : https://run.dlang.io/is/Bsf8Us Works if struct Foo is defined in the scope of struct Bar(T) ?
Aug 23 2018
prev sibling parent reply Jonathan Marler <johnnymarler gmail.com> writes:
On Thursday, 23 August 2018 at 19:48:19 UTC, Robert burner 
Schadek wrote:
 It is still rough around the corners and 
 https://issues.dlang.org/show_bug.cgi?id=19084 gives me 
 somewhat of a hard time, but give it try and scream at me 
 because it is not nogc.
I've posted a comment on issue 19084 but I'll post the response here as well. This is not supposed to compile. I've actually run into this before, but using T.stringof to mixin code for a type name is not supported. When I've asked about adding support for this, no one was interested. I tried to find my forum posts on this but the post is so old I couldn't find it in search. What happens is you mixin the string "Foo", but that type doesn't mean anyting in the scope of Bar. The actual type name is something like "__unittest__20.Foo", however, even if you got the fully qualified type name it won't work because the type is private and can't be accessed outside of the unittest using the symbol name. You have to access the type by "alias". The `bitfields` function in phobos suffers from this same problem and I created a PR in phobos to add bitfields2 to workaround this issue by using a "mixin template" instead of a normal "mixin": https://github.com/dlang/phobos/pull/5490
 [QUOTE FROM THE PR]
 The main advantage of bitfields2 is that it is able to 
 reference the field types by alias, whereas the current 
 implementation converts each field type alias to a string and 
 then mixes in the type name.
I know the example you've provided is contrived so I'm not sure how to help you with your exact situation. Maybe I can help you find a solution with a bit more detail?
Aug 23 2018
parent Lurker!(me) <lurker spamfree.org> writes:
On Friday, 24 August 2018 at 03:47:03 UTC, Jonathan Marler wrote:
  I tried to find my forum posts on this but the post is so old 
 I couldn't find it in search.
You mean this? https://forum.dlang.org/thread/ibwazxrngcsrfolgbefs forum.dlang.org
Aug 24 2018