mirror of
https://github.com/lensapp/lens.git
synced 2025-05-20 05:10:56 +00:00
WIP Kludge "moduleResolution": "node16"
Signed-off-by: Iku-turso <mikko.aspiala@gmail.com>
This commit is contained in:
parent
4ae90c46c7
commit
5286e5f54b
@ -8,7 +8,7 @@ import path from "path";
|
||||
export type JoinPaths = (...args: string[]) => string;
|
||||
|
||||
const joinPathsInjectable = getInjectable({
|
||||
id: "join-paths",
|
||||
id: "join-paths-1",
|
||||
instantiate: (): JoinPaths => path.join,
|
||||
|
||||
// This causes side effect e.g. Windows uses different separator than e.g. linux
|
||||
|
||||
@ -88,6 +88,7 @@ const toNavigationHierarchy = (composite: Composite<PreferenceItemTypes | Prefer
|
||||
}
|
||||
|
||||
default: {
|
||||
// @ts-ignore
|
||||
throw checkThatAllDiscriminablesAreExhausted(value);
|
||||
}
|
||||
}
|
||||
|
||||
@ -95,6 +95,7 @@ const toPreferenceItemHierarchy = (composite: Composite<PreferenceItemTypes>) =>
|
||||
}
|
||||
|
||||
default: {
|
||||
// @ts-ignore
|
||||
throw checkThatAllDiscriminablesAreExhausted(value);
|
||||
}
|
||||
}
|
||||
|
||||
@ -4,6 +4,7 @@
|
||||
*/
|
||||
|
||||
import { registerFeature } from "@lensapp/feature-core";
|
||||
import appPathsFeature from "@lensapp/app-paths";
|
||||
import fsFeature from "@lensapp/fs";
|
||||
import loggingFeature from "@lensapp/logging";
|
||||
import shellFeature from "@lensapp/shell";
|
||||
@ -13,6 +14,7 @@ import type { DiContainer } from "@ogre-tools/injectable";
|
||||
import { action } from "mobx";
|
||||
|
||||
export default action((di: DiContainer) => {
|
||||
registerFeature(di, appPathsFeature);
|
||||
registerFeature(di, clusterFeature);
|
||||
registerFeature(di, fsFeature);
|
||||
registerFeature(di, loggingFeature);
|
||||
|
||||
@ -46,6 +46,8 @@ import assert from "assert";
|
||||
import startFrameInjectable from "./start-frame/start-frame.injectable";
|
||||
import initializeSentryReportingWithInjectable from "../common/error-reporting/initialize-sentry-reporting.injectable";
|
||||
import registerFeatures from "./register-features";
|
||||
import { RootFrame } from "./frames/root-frame/root-frame";
|
||||
import { ClusterFrame } from "./frames/cluster-frame/cluster-frame";
|
||||
|
||||
configurePackages(); // global packages
|
||||
registerCustomThemes(); // monaco editor themes
|
||||
@ -157,10 +159,10 @@ export async function bootstrap(di: DiContainer) {
|
||||
// TODO: Introduce proper architectural boundaries between root and cluster iframes
|
||||
if (process.isMainFrame) {
|
||||
initializeApp = di.inject(initRootFrameInjectable);
|
||||
App = (await import("./frames/root-frame/root-frame")).RootFrame;
|
||||
App = RootFrame;
|
||||
} else {
|
||||
initializeApp = di.inject(initClusterFrameInjectable);
|
||||
App = (await import("./frames/cluster-frame/cluster-frame")).ClusterFrame;
|
||||
App = ClusterFrame;
|
||||
}
|
||||
|
||||
try {
|
||||
|
||||
@ -12,7 +12,7 @@ import TreeItem from "@material-ui/lab/TreeItem";
|
||||
import { cssNames } from "../../utils";
|
||||
|
||||
import _ from "lodash";
|
||||
import getDeepDash from "deepdash";
|
||||
const getDeepDash = require("deepdash");
|
||||
|
||||
const deepDash = getDeepDash(_);
|
||||
|
||||
@ -33,6 +33,7 @@ function scrollToItem(id: string) {
|
||||
}
|
||||
|
||||
function getSelectedNode(data: NavigationTree[]) {
|
||||
// @ts-ignore
|
||||
return deepDash.findDeep(data, (value, key) => key === "selected" && value === true)?.parent;
|
||||
}
|
||||
|
||||
|
||||
@ -9,7 +9,7 @@
|
||||
"DOM",
|
||||
"DOM.Iterable"
|
||||
],
|
||||
"moduleResolution": "Node",
|
||||
"moduleResolution": "node16",
|
||||
"sourceMap": true,
|
||||
"strict": true,
|
||||
"noImplicitAny": true,
|
||||
|
||||
Loading…
Reference in New Issue
Block a user