2024-07-23 13:57:22 +03:00
|
|
|
# Daletl specification for Dalet v1.0-preview
|
|
|
|
|
2024-07-28 20:21:22 +03:00
|
|
|
## Daletl
|
|
|
|
|
2024-08-01 15:54:24 +03:00
|
|
|
Daletl is data representation of serialized/deserialized [DaletPack](./daletpack.md).
|
2024-07-23 13:57:22 +03:00
|
|
|
|
|
|
|
### Root
|
|
|
|
|
2024-07-28 20:21:22 +03:00
|
|
|
Daletl root is array of tags. For convenience, we will use the typescript notation.
|
2024-07-23 13:57:22 +03:00
|
|
|
|
2024-07-28 20:21:22 +03:00
|
|
|
```typescript
|
|
|
|
type Root = Tag[];
|
2024-07-23 13:57:22 +03:00
|
|
|
```
|
|
|
|
|
|
|
|
### Tag
|
|
|
|
|
|
|
|
All tags specification is in [Tags](./tags.md).
|
|
|
|
|
2024-07-28 20:21:22 +03:00
|
|
|
```typescript
|
|
|
|
interface Tag {
|
|
|
|
id: number;
|
2024-07-28 22:30:19 +03:00
|
|
|
body: string | Tag[] | null;
|
2024-07-28 20:21:22 +03:00
|
|
|
argument: string | number | null;
|
|
|
|
}
|
2024-07-24 16:41:50 +03:00
|
|
|
```
|
|
|
|
|
2024-07-28 20:21:22 +03:00
|
|
|
### Example
|
2024-07-24 16:41:50 +03:00
|
|
|
|
2024-07-28 20:21:22 +03:00
|
|
|
```typescript
|
|
|
|
const root: Root = [
|
|
|
|
{
|
|
|
|
id: 1,
|
|
|
|
body: "I am Heading with level 1",
|
|
|
|
argument: 1,
|
|
|
|
},
|
|
|
|
];
|
2024-07-24 16:41:50 +03:00
|
|
|
```
|