Files
GitJournal/lib/markdown/markdown.proto
Vishesh Handa 64faba451e Try to implement a markdown codec
This is serializing it into bytes via protobuf. The idea is to avoid the
expensive parsing of the markdown multiple times, and instead just cache
the result.
2021-09-19 11:16:41 +02:00

28 lines
428 B
Protocol Buffer

/*
* SPDX-FileCopyrightText: 2019-2021 Vishesh Handa <me@vhanda.in>
*
* SPDX-License-Identifier: AGPL-3.0-or-later
*/
syntax = "proto3";
package gitjournal;
message NodeList {
repeated Node node = 1;
}
message Node {
oneof value {
Element element = 1;
string text = 2;
}
}
message Element {
string tag = 1;
map<string, string> attributes = 2;
repeated Node children = 3;
string generatedId = 4;
}