DEV Community

Discussion on: Why I didn't just use NgRx, NGXS or Subjects in a Service

Collapse
 
mfp22 profile image
Mike Pearson

I'm currently helping a team upgrade from AngularJS to Angular and haven't had time recently, but in the next couple of weeks I will be getting back to StateAdapt, and I should have several months to work on it and write about it. I was about to release documentation for the adapter library and a couple of adapters to start with, and then version 1.0 shortly after that. Nothing fundamental will be changing though I don't think, so if you feel like using it in production, I don't see an issue with it. Check out the website to make sure you've got the core concepts down and let me know if you have questions.

Collapse
 
timsar2 profile image
timsar2

Two years later, I'm still looking for version 1.0 StateAdapt :D

Thread Thread
 
mfp22 profile image
Mike Pearson

Yeah...

I'm releasing an article in 16 hours explaining the most recent bug I found. It almost caused a fundamental API change, so I'm glad I found it before 1.0.

But I've implemented it in 20-30 projects now and feel really good about it after this last bugfix. I have a bunch of unit tests covering everything I've found. I haven't used in in a humongous project yet, but I've used it in medium-sized projects and my confidence in it is pretty high. The last project I did was what made me discover the last major bug I think, so doing these projects has been valuable.

Here's the last official issue required for 1.0 github.com/state-adapt/state-adapt...

But my unofficial todo list currently looks like this
Image description

It will probably take an extra week, and I'm thinking of waiting for Angular 15 to release 1.0 as well, but not sure on that. So, I'll say either 11/22 or when Angular 15 comes out.

Thread Thread
 
mfp22 profile image
Mike Pearson

The Angular library is ready to use in production I think.

1.0 is only delayed now because I already had a React implementation and wanted to test it for 1.0 to release at the same time as the Angular library.

Just make sure @state-adapt/core @state-adapt/rxjs @state-adapt/angular are all on the same version. There was an issue with ng-packagr that caused one of them to have a stupid peer dependency. node.js 14 had an issue with it with npm install, but I think everything else is fine.

Thread Thread
 
timsar2 profile image
timsar2

Congratulations, Can you please make an example of how to use it without zonejs like rx-angular.
Rx-angular has template library and it's missing in other, is it worth to use both stateAdapt and rx-angular template together?

Thread Thread
 
mfp22 profile image
Mike Pearson

Yes, use them both. No reason to re-implement RxAngular's innovations for templates.

This is an example of Todo MVC that I forked from the RxAngular implementation, which I believe is zoneless. It's a 3-month old example, but I don't think any API I used has changed. github.com/mfp22/state-adapt-todo-mvc

The next couple of days will be finishing up documentation. I'll comment again when the new docs site is live.

Thread Thread
 
mfp22 profile image
Mike Pearson

And here's a diff between the RxState and StateAdapt implementations
github.com/edbzn/rx-angular-todo-m...

Thread Thread
 
timsar2 profile image
timsar2 • Edited

I run it, new todo does not added to the list

Thread Thread
 
mfp22 profile image
Mike Pearson

Any console errors?

Thread Thread
 
timsar2 profile image
timsar2 • Edited

I'm sorry It was my mistake, It's working right.