From 925587c1b21e9154c4b5dfc74d33ab4680235825 Mon Sep 17 00:00:00 2001
From: Jan Tuomi <jans.tuomi@gmail.com>
Date: Mon, 7 Feb 2022 16:24:33 +0200
Subject: Fix API types

---
 src/Editor.tsx | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

(limited to 'src/Editor.tsx')

diff --git a/src/Editor.tsx b/src/Editor.tsx
index 2fff5b9..b0441d7 100644
--- a/src/Editor.tsx
+++ b/src/Editor.tsx
@@ -35,7 +35,9 @@ const Editor = () => {
           An unexpected error occurred while loading examples. See console for details.
         </div>
       case "success": {
-        const options = examples.data.map(example => ({ value: example.content, label: example.title }))
+        const options = examples.data.examples.map(example => ({
+          value: example.content, label: example.title,
+        }))
         const customStyles = {
           option: (styles: any) => ({
             ...styles,
-- 
cgit v1.3

