Skip to content
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

Convert all models to object type literals #273

Open
alancleary opened this issue Mar 25, 2020 · 0 comments
Open

Convert all models to object type literals #273

alancleary opened this issue Mar 25, 2020 · 0 comments

Comments

@alancleary
Copy link
Contributor

Currently many model types in the GCV are defined as classes. While this is useful when types are required to have methods as attributes this is mostly not the case. Any additional class related benefits are lost due to GCV's use of prototype-based mixins to add attributes to existing objects without mutation or duplication.

The main motivation for this change is to enable support for NgRx Store state serialization. Object type literals are serializable, whereas classes are not. By switching to object type literals, the store will be serializable, thus enabling additional functionality, such as support for GoldenLayout's popout windows which requires passing a copy of the application state to the poped out window.

@alancleary alancleary mentioned this issue Aug 17, 2023
20 tasks
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant