We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent cb57996 commit 2bdfacbCopy full SHA for 2bdfacb
pcweb/pages/docs/custom_components.py
@@ -1,6 +1,7 @@
1
import reflex as rx
2
import httpx
3
import json
4
+import os
5
from rxconfig import config
6
import reflex_chakra as rc
7
from pcweb.templates.docpage import docpage, h1_comp, text_comp_2
@@ -21,7 +22,9 @@ class CustomComponentGalleryState(rx.State):
21
22
@rx.event
23
def fetch_components_list(self):
24
try:
- response = httpx.get(f"{config.cp_backend_url}/custom-components/gallery")
25
+ response = httpx.get(
26
+ f"{os.getenv("RCC_ENDPOINT")}/custom-components/gallery"
27
+ )
28
response.raise_for_status()
29
component_list = response.json()
30
except (httpx.HTTPError, json.JSONDecodeError) as ex:
0 commit comments