feat: permit custom state types
Problem: Currently, the macro does not support user-defined state enums. This limitation is particularly noticeable when users require fine-grained control over Serde serialization/deserialization, specifically when needing to leverage attributes like skip and default.
Solution: Support a custom_state attribute. Permit users to define their own external state type that will be used. Skip generating enum and constructor definitions in this event.
Testing: Implemented an example and added UI test cases.
Issue: https://github.com/mdeloof/statig/issues/43
@mdeloof, here's a first pass. Let me know your initial thoughts!
@christianheussy It's looking good! I'm wondering if we should maybe opt to simply use custom (or maybe manual ) instead of custom_state as it's already a sub-attribute of state?
@christianheussy Are you still able to work on this? If not, is it ok for you if I finish up the work so it can be merged? :)
Yes, will take a look over the weekend!
@mdeloof updated to use custom as the literal. Let me know if you have other suggested changes!
Thanks!