mirror of
https://github.com/Unleash/unleash.git
synced 2025-10-13 11:17:26 +02:00
We're migrating to ESM, which will allow us to import the latest versions of our dependencies. Co-Authored-By: Christopher Kolstad <chriswk@getunleash.io>
15 lines
484 B
TypeScript
15 lines
484 B
TypeScript
import useProjectOverview from './api/getters/useProjectOverview/useProjectOverview.js';
|
|
|
|
const DEFAULT_STICKINESS = 'default';
|
|
export const useDefaultProjectSettings = (projectId: string) => {
|
|
const { project, loading, error } = useProjectOverview(projectId);
|
|
return {
|
|
defaultStickiness: project.defaultStickiness
|
|
? project.defaultStickiness
|
|
: DEFAULT_STICKINESS,
|
|
mode: project.mode,
|
|
loading: loading,
|
|
error,
|
|
};
|
|
};
|