Convert DirectoryForExes to LazyInitializableState

Signed-off-by: Sebastian Malton <sebastian@malton.name>
This commit is contained in:
Sebastian Malton committed 2022-10-31 14:42:03 -04:00
1 parent ce0c924c00
commit 1c4e620e38
2 files changed
+13 -13

No files matched your search

@@ -0,0 +1,13 @@
/**
* Copyright (c) OpenLens Authors. All rights reserved.
* Licensed under MIT License. See LICENSE in root directory for more information.
*/
import { createLazyInitializableState } from "../initializable-state/create-lazy";
import { appPathsInjectionToken } from "./token";
const directoryForExesInjectable = createLazyInitializableState({
id: "directory-for-exes",
init: (di) => di.inject(appPathsInjectionToken).get().exe,
});
export default directoryForExesInjectable;
@@ -1,13 +0,0 @@
/**
* Copyright (c) OpenLens Authors. All rights reserved.
* Licensed under MIT License. See LICENSE in root directory for more information.
*/
import { getInjectable } from "@ogre-tools/injectable";
import { appPathsInjectionToken } from "../app-path-injection-token";
const directoryForExesInjectable = getInjectable({
id: "directory-for-exes",
instantiate: (di) => di.inject(appPathsInjectionToken).exe,
});
export default directoryForExesInjectable;