MCPcopy Create free account
hub / github.com/tensorflow/tensorboard / createCoreState

Function createCoreState

tensorboard/webapp/core/testing/index.ts:54–79  ·  view source on GitHub ↗
(override?: Partial<CoreState>)

Source from the content-addressed store, hash-verified

52}
53
54export function createCoreState(override?: Partial<CoreState>): CoreState {
55 return {
56 activePlugin: null,
57 plugins: {},
58 coreDataLoadState: {
59 state: DataLoadState.NOT_LOADED,
60 lastLoadedTimeInMs: null,
61 },
62 pluginsListLoaded: {
63 state: DataLoadState.NOT_LOADED,
64 lastLoadedTimeInMs: null,
65 failureCode: null,
66 },
67 environment: createEnvironment(),
68 polymerRunsLoadState: {
69 state: DataLoadState.NOT_LOADED,
70 lastLoadedTimeInMs: null,
71 },
72 polymerInteropRuns: [],
73 polymerInteropRunSelection: new Set(),
74 sideBarWidthInPercent: 0,
75 runsTableFullScreen: false,
76 unknownQueryParams: {},
77 ...override,
78 };
79}
80
81export function createState(coreState: CoreState = createCoreState()): State {
82 return {[CORE_FEATURE_KEY]: coreState};

Callers 7

header_test.tsFile · 0.90
buildMockStateFunction · 0.90
createStateFunction · 0.85

Calls 1

createEnvironmentFunction · 0.85

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…