small SPA gleam experiment to fetch and render a single bsky post
1{
2 "text": "Hello @alice.bsky.social! Check out https://example.com #bluesky #atproto",
3 "langs": ["en", "es"],
4 "createdAt": "2024-01-15T10:30:00.000Z",
5 "facets": [
6 {
7 "index": {
8 "byteStart": 7,
9 "byteEnd": 22
10 },
11 "features": [
12 {
13 "$type": "app.bsky.richtext.facet#mention",
14 "did": "did:plc:z72i7hdynmk6r22z27h6tvur"
15 }
16 ]
17 },
18 {
19 "index": {
20 "byteStart": 34,
21 "byteEnd": 53
22 },
23 "features": [
24 {
25 "$type": "app.bsky.richtext.facet#link",
26 "uri": "https://example.com"
27 }
28 ]
29 },
30 {
31 "index": {
32 "byteStart": 55,
33 "byteEnd": 63
34 },
35 "features": [
36 {
37 "$type": "app.bsky.richtext.facet#tag",
38 "tag": "bluesky"
39 }
40 ]
41 },
42 {
43 "index": {
44 "byteStart": 64,
45 "byteEnd": 73
46 },
47 "features": [
48 {
49 "$type": "app.bsky.richtext.facet#tag",
50 "tag": "atproto"
51 }
52 ]
53 }
54 ],
55 "labels": {
56 "values": [
57 { "val": "nsfw" }
58 ]
59 },
60 "tags": ["bluesky", "atproto"],
61 "embed": {
62 "$type": "app.bsky.embed.images",
63 "images": [
64 {
65 "image": {
66 "$link": "bafkreihdilz3zvh3gkv7cm7g7l5v2g6g6g6g6g6g6g6g6g6g6g6g6g6g"
67 },
68 "alt": "A beautiful sunset over the mountains",
69 "aspectRatio": {
70 "width": 1920,
71 "height": 1080
72 }
73 },
74 {
75 "image": {
76 "$link": "bafkreigh5aer2g4h4h4h4h4h4h4h4h4h4h4h4h4h4h4h4h4h4"
77 },
78 "alt": "A cat sleeping on a couch",
79 "aspectRatio": {
80 "width": 1200,
81 "height": 800
82 }
83 }
84 ]
85 }
86}