You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The base HarRecorder doesn't need to subscribe to events (as it should be done by the consumer). So the call to startRecording is only there to reset the state before we record event.
Meaning we could make startRecording optional, and the first call to recordEvent could take care of resetting the state when needed. Or we can completely remove startRecording. This would leave us with only two public methods on this recorder: recordEvent and stopRecording.
Maybe we should just remove any notion of state from this class and just have two methods: recordEvent and exportAsHar, and then consumers would just create a new recorder for each record they want to build?
The text was updated successfully, but these errors were encountered:
The base HarRecorder doesn't need to subscribe to events (as it should be done by the consumer). So the call to startRecording is only there to reset the state before we record event.
Meaning we could make startRecording optional, and the first call to recordEvent could take care of resetting the state when needed. Or we can completely remove startRecording. This would leave us with only two public methods on this recorder: recordEvent and stopRecording.
Maybe we should just remove any notion of state from this class and just have two methods: recordEvent and exportAsHar, and then consumers would just create a new recorder for each record they want to build?
The text was updated successfully, but these errors were encountered: