summaryrefslogtreecommitdiff
path: root/blog/2023/02/11/planning.mdwn
blob: a6a524cd67dbcb7feb630083fe5c29c0171130a2 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
[[!meta title="Iteration planning: February 11-23"]]
[[!meta date="2023-02-11 15:50:00 +0000"]]
[[!tag meeting]]

# Notes

We decided to not follow the usual meeting structure and instead only
discussed how to refactor the Subplot code base.

We've reached a stage where the next thing to do is to replace the
Pandoc (or `pandoc_ast`) representation of a parsed Markdown document
with one of our own. We don't like the Pandoc one for the things we
want to do, and would prefer a more malleable one. In addition, the
Pandoc one has changed in incompatible ways before, making it harder
for us to use it.

We discussed what we want from such a representation and came up with
a plan. For this iteration:

* Daniel will refactor the `Document` methods to avoid requiring a
  mutable reference to self, when possible.
* Lars will refactor `Document` to drop the `markdowns` fields and the
  `Document::sources` method to get the information from the document
  metadata instead.
* Lars will change Subplot to drop direct support for generating PDF.
  We decided that for now, we only care about HTML output. We may add
  PDF support back later, but it'll be easier to not need have that
  while we are redoing document parsing. In any case, we've verified
  that producing a reasonable PDF with Pandoc from the HTML output is
  feasible.
* Lars will drop `pandoc_ast` as a dependency in favor of
  `pulldown_cmark`, and a custom representation of a parsed Markdown
  document. Lars will probably use a lightweight abstraction for HTML,
  and rewrite the `pandoc_ast::MutVisitor` use to query that instead.
* Lars will drop the `Markdown::set_metatdata` method and instead give
  the `YamlMetadata` directly to `Markdown::to_json`. From the
  caller's point of view, there's no need to have two methods for
  this. Or possibly Lars will just drop both methods, if they're not
  needed for HTML generation.



# Meeting participants

- Daniel Silverstone
- Lars Wirzenius