Skip to content

Commit 2fd20b9

Browse files
committed
feat(overmind): show hint about port and how to connect
1 parent e5383b4 commit 2fd20b9

File tree

2 files changed

+13
-1
lines changed

2 files changed

+13
-1
lines changed

packages/node_modules/overmind-devtools-client/src/components/Devtools/index.tsx

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -62,9 +62,15 @@ const Devtools: FunctionComponent = () => {
6262
)
6363
}
6464

65+
let text =`const overmind = createOvermind(config, {
66+
devtools: "localhost:${state.port}",
67+
})`
6568
return state.isConnecting ? (
6669
<div className={styles.wrapper}>
67-
<h1>Waiting for an app to connect...</h1>
70+
<h1>Waiting for an app to connect to {state.port}...</h1>
71+
<pre className={styles.code}>
72+
{text}
73+
</pre>
6874
</div>
6975
) : (
7076
<Workspace />

packages/node_modules/overmind-devtools-client/src/components/Devtools/styles.ts

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -25,3 +25,9 @@ export const input = css({
2525
outline: 'none',
2626
borderRadius: 3,
2727
})
28+
29+
export const code = css({
30+
border: '2px dashed var(--colors-white4)',
31+
padding: '10px',
32+
background: 'var(--colors-black2)'
33+
})

0 commit comments

Comments
 (0)