mirror of
https://github.com/mountain-loop/yaak.git
synced 2025-12-23 22:48:55 -05:00
* Update environment model to get ready for request/folder environments * Folder environments in UI * Folder environments working * Tweaks and fixes * Tweak environment encryption UX * Tweak environment encryption UX * Address comments * Update fn name * Add tsc back to lint rules * Update src-web/components/EnvironmentEditor.tsx * Merge remote-tracking branch 'origin/folder-environments' into folder…
9 lines
377 B
TypeScript
9 lines
377 B
TypeScript
import { useAtomValue } from 'jotai';
|
|
import { activeEnvironmentAtom } from './useActiveEnvironment';
|
|
import { useEnvironmentVariables } from './useEnvironmentVariables';
|
|
|
|
export function useActiveEnvironmentVariables() {
|
|
const activeEnvironment = useAtomValue(activeEnvironmentAtom);
|
|
return useEnvironmentVariables(activeEnvironment?.id ?? null).map((v) => v.variable);
|
|
}
|