Skip to content

Remove startRecording for HarRecorder #4

@juliandescottes

Description

@juliandescottes

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?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions