I'm coming to you with an idea of a new format for Joplin.
My problem stems from the fact that I'm using and enjoying the way OneNote organizes page - it allows for content to be placed independently; but at the same time I'm limited to their editor.
By introducing a container, Joplin could have several new features:
Ability to position elements on page at any place
Ability to include in a single page different formats (MD, Asciidoc and wysiwyg-generated HTML to name a few). This would decouple rendering and format from Joplin
...which in turn would handle other limitations like MD tables and image positioning
Details:
As this is a container format; it is trivially easy to create from/export to a single document. This would also allow to create a pluggable renderer/editor for each content type.
At this point, I am working on a PoC implementation, using yaml as a container (I know, not a perfect format - but this is PoC )
Question is - would Joplin be interested in adopting a separate format; or would you rather stick to markdown?
Sure, this is why I've started with YAML - or any plain text really. The way I'd see it, is:
# sample-file.onote
# This is a sample file, with metadata omitted for brevity.
outlines:
# This was created in application
- metadata:
type: markdown
content: |
# Example type
# This one was imported - notice original file name in metadata
- metadata:
originalFileName: "filename.adoc"
type: asciidoc
content: |
example
# Sample file without title or original filename
- metadata:
type: xml
content: |
<document/>
So for degradation:
in case of no renderers available, we can always print the plain text for each outline.
File in case of YAML example is perfectly readable as plain text; and as such can be manipulated (With e.g. JG, so export script outside of the Joplin could be done easily)
In the application itself, I'd see export as action that splits the original file, using the example:
(After export action)
sample-file_Example_title.md // Prefix from note name, then normalized first sentence, then filetype from type
sample-file_filename.adoc // This one was imported, so we export almost 'as was'
sample-file_1.xml // Either incremented, or maybe UUID? Another option would be to use a trick from the OneNote book and use the first sentence of an outline
Does that answer your question?
I'm still working on a POC and I'll soon be ready to show it off. 95% of it is written with React, so it should be quite portable.
I'm developing this for myself - as this is the single thing that keeps me out of Joplin. So either Joplin is interested - I'll be happy to contribute; or I'll keep it as VSCode plug-in.