Skip to content

Conversation

@DevYeom
Copy link
Owner

@DevYeom DevYeom commented Nov 9, 2025

Related Issues 💭

Description 📝

  • This PR introduces a configurable logging mechanism to the Store to help with debugging. Developers can now enable logging for actions and state changes, with fine-grained control over what is logged.

Additional Notes 📚

@StateObject private var store = ViewStore(
    reducer: HomeReducer(),
    state: HomeReducer.State()
)
.debug(.all)
[2025-11-09T04:42:58.956Z] Action: increment
[2025-11-09T04:42:58.956Z] State changed:
- State(count: 0, text: "")
+ State(count: 1, text: "")
[2025-11-09T04:42:58.956Z] Action: increment
[2025-11-09T04:42:58.956Z] State changed:
- State(count: 1, text: "")
+ State(count: 2, text: "")
[2025-11-09T04:42:58.956Z] Action: twice
[2025-11-09T04:42:58.956Z] Action: increment
[2025-11-09T04:42:58.957Z] State changed:
- State(count: 2, text: "")
+ State(count: 3, text: "")
[2025-11-09T04:42:58.957Z] Action: increment
[2025-11-09T04:42:58.957Z] State changed:
- State(count: 3, text: "")
+ State(count: 4, text: "")

Checklist ✅

  • If it's a new feature, have appropriate unit tests been added?
  • If the changes affect existing functionality, please verify whether the above information has been appropriately described.

@DevYeom DevYeom self-assigned this Nov 9, 2025
@DevYeom DevYeom merged commit 7f5dcb0 into main Nov 9, 2025
2 checks passed
@DevYeom DevYeom deleted the log branch November 9, 2025 04:53
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants