From 4d197aaeea7a5608b1b6c954f6d0bfdee5e43407 Mon Sep 17 00:00:00 2001 From: florian <> Date: Fri, 8 Mar 2024 20:16:16 +0000 Subject: [PATCH] feat: Added env settings for image proxy --- .env.sample | 2 ++ TODO.md | 5 +---- src/components/env.ts | 5 ++++- 3 files changed, 7 insertions(+), 5 deletions(-) create mode 100644 .env.sample diff --git a/.env.sample b/.env.sample new file mode 100644 index 0000000..173e596 --- /dev/null +++ b/.env.sample @@ -0,0 +1,2 @@ +VITE_APP_NAME=slidestr.net +VITE_IMAGE_PROXY=https://imgproxy.slidestr.net diff --git a/TODO.md b/TODO.md index 16c539f..048eb73 100644 --- a/TODO.md +++ b/TODO.md @@ -1,11 +1,7 @@ # TODO - add load more, to load older events -- repair auto login -- store NIP46 secret key - Fix/Test zaps - Reimplement Likes/Zaps based in ngine code -- Investigate profile caching - - Avatar display is laggy, needs caching - move settings dialog to main start screen - replace search icon with nav back button - record demo explaination video @@ -17,3 +13,4 @@ - think about use of ui framework, and redesign settings dialog - move NSFW block list into a list event on an slidestr.net profile (public nsfw mute list) - Add key/salt to imageproxy, see snort impl +- caching of preprocessed images with index? diff --git a/src/components/env.ts b/src/components/env.ts index 00ac394..e8fa960 100644 --- a/src/components/env.ts +++ b/src/components/env.ts @@ -1,6 +1,9 @@ import { nip19 } from 'nostr-tools'; -export const appName = 'slidestr.net'; +export const imageProxy = import.meta.env.VITE_IMAGE_PROXY || 'https://imgproxy.slidestr.net'; + +export const appName = import.meta.env.VITE_APP_NAME || 'slidestr.net'; + type Topic = { name?: string; tags: string[];