No stylesheet in exported HTML files

Steps to reproduce

  1. Go to “☰ → Export … → Formatted”, starting from the context menu of any node in a Dynalist document.

  2. Click “Download as file” and save it to disk somewhere.

  3. Open the file in a text editor and observe that it starts with !DOCTYPE html><html><body><ul>....

Expected result

There should be a <head> section in the document including an inlined CSS stylesheet, providing necessary formatting, for example the CSS added recently to be able to see leading whitespace after a line break.

Actual result

There is no <head> section and no CSS styling in the document.

Environment

Firefox under Ubuntu Linux 19.10. Tested in private mode (so, without browser extensions).

I believe this is feature request rather than a bug. Space collapsing, unless otherwise specified, is a HTML thing, and the file is being faithfully exported as HTML.

Looking at your use case, it probably makes more sense to make a feature request so that exported inline code or code blocks are exported properly as <code> or <pre>. In most cases white space doesn’t matter, and in cases which it should matter, using inline code or code block in Dynalist signifies that.