I’m working with
@codemirror/fold right now and I have not found a good way to request for the currently folded regions.
The use case I’m going after is to persist the fold status by line number in hopes of restoring it in a later writing session. This could be done previously on CM5 with
getAllMarks() and querying the (undocumented)
__isFold property on a Mark object.
So the question is: would it make sense to add some kind of API to get all currently folded regions, or should I be looking into writing a custom fold plugin?
PS. It might also make sense to add an API for querying whether a single line is folded, which could be useful for, say, implementing a