Skip to content

Commit 262a289

Browse files
eirikhmchristianalfoni
authored andcommitted
fix(overmind): remove unused code and imports
1 parent 72a26d5 commit 262a289

File tree

3 files changed

+5
-24
lines changed

3 files changed

+5
-24
lines changed

packages/node_modules/overmind-devtools-vscode/README.md

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -31,11 +31,8 @@ This extension contributes the following settings:
3131
## Known Issues
3232

3333
* Relaunch does not work.
34-
* overmind-devtools-client dist files are manually copied into overmind-devtools-vscode
35-
* storage in overmind-devtools-vscode is a dummy, and must be updated to VSCode APIs
3634
* DevtoolsPanel needs a refactor and must implement more VS apis
3735

38-
3936
## Release Notes
4037

4138
TODO

packages/node_modules/overmind-devtools-vscode/src/DevtoolsPanel.ts

Lines changed: 1 addition & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,15 +1,11 @@
11
import * as vscode from 'vscode'
2-
import * as path from 'path'
32
import { log } from './utils/Logger'
43

54
export class DevtoolsPanel {
65
public static currentPanel: DevtoolsPanel | undefined
76

87
public static viewType = 'overmindDevtools'
98

10-
// keeps track of location for overmind-devetools js bundle
11-
// public static scriptFile: any = null
12-
139
private readonly _panel: vscode.WebviewPanel
1410

1511
private _disposables: vscode.Disposable[] = []
@@ -98,9 +94,7 @@ export class DevtoolsPanel {
9894
{
9995
enableScripts: true,
10096
retainContextWhenHidden: true,
101-
localResourceRoots: [
102-
vscode.Uri.file(path.join(extensionPath, 'devtoolsDist')),
103-
],
97+
localResourceRoots: [],
10498
}
10599
)
106100

packages/node_modules/overmind-devtools-vscode/src/extension.ts

Lines changed: 4 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -1,32 +1,29 @@
11
import * as vscode from 'vscode'
22
import { DevtoolsPanel } from './DevtoolsPanel'
3-
import * as path from 'path'
43
import { log } from './utils/Logger'
54

65
// this method is called when your extension is activated
76
// your extension is activated the very first time the command is executed
87
export function activate(context: vscode.ExtensionContext) {
98
const storage = {
10-
get(key:string){
9+
get(key: string) {
1110
return new Promise((resolve) => {
1211
resolve(context.workspaceState.get(key))
1312
})
1413
},
1514

16-
set (key:string, value: any)
17-
{
15+
set(key: string, value: any) {
1816
return new Promise((resolve) => {
1917
context.workspaceState.update(key, value)
2018
resolve()
2119
})
2220
},
2321

24-
clear()
25-
{
22+
clear() {
2623
return new Promise((resolve) => {
2724
resolve()
2825
})
29-
}
26+
},
3027
}
3128

3229
const DevtoolBackend = require('overmind-devtools-client/DevtoolBackend')
@@ -38,15 +35,8 @@ export function activate(context: vscode.ExtensionContext) {
3835
storage,
3936
})
4037

41-
4238
context.subscriptions.push(
4339
vscode.commands.registerCommand('overmind-devtools.start', () => {
44-
// const onDiskPath = vscode.Uri.file(
45-
// path.join(context.extensionPath, '../overmind-devtools-client/dist/', 'bundle.js')
46-
// )
47-
// const scriptFile = onDiskPath.with({ scheme: 'vscode-resource' })
48-
49-
// DevtoolsPanel.scriptFile = scriptFile
5040
DevtoolsPanel.createOrShow(context.extensionPath) // refactor to keep local reference to panel
5141
})
5242
)

0 commit comments

Comments
 (0)