Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Changes by icoco re: Desktop app #690

Open
wants to merge 4 commits into
base: main
Choose a base branch
from
Open

Conversation

curran
Copy link
Contributor

@curran curran commented May 24, 2024

Creating this PR to see the changes clearly from @icoco . Thank you for this!

Copy link
Contributor Author

@curran curran left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@icoco There's a lot going on here!

It looks like you needed to make some adaptations for your use cases of VZCode, but did not consider the changes as contributions to VZCode.

I'd be happy to incorporate your improvements to mainline VZCode. That would be beneficial to you, since you won't need to maintain a separate fork.

I would encourage you to review the contribution guidelines, open new issues for each thing you need, then open separate PRs that close each of the issues.

Certain things may only be relevant to your use case, in which case they can be put behind a feature flag.

Thanks for working on VZCode!

if ( globalThis.wss){
return ;
try{
globalThis.connection.close();
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why is globalThis required?

);
const connection = new Connection(socket);
globalThis.wss = socket;
globalThis.connection = Connection;
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why are these exposed in this way?

import { Request } from "../utils/Request.js";

// get the docId from the current url request paramter
export const getRequestDocId = function(){
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Whoah this is cool! I'd like to learn more about what is going on here. What is the doc id? What is this used for?

@@ -0,0 +1,5 @@
.AppShell {
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

What is this for?

const fetchDocStatus = reloadDocThen()

function AppShell() {
const docStatus = fetchDocStatus.read();
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

docStatus is not used. What does .read() do here?

@@ -9,6 +9,10 @@ import { json } from '@codemirror/lang-json';
import { markdown } from '@codemirror/lang-markdown';
import { html } from '@codemirror/lang-html';
import { css } from '@codemirror/lang-css';

import { xml } from '@codemirror/lang-xml';
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Very nice! These could be separate PRs, I would accept these by themselves.

@@ -29,7 +29,7 @@ export const Listing = ({
name={name}
handleFileClick={handleFileClick}
handleFileDoubleClick={handleFileDoubleClick}
isActive={fileId === activeFileId}
isActive={fileId === globalThis.activeFileId }
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Super sketchy. Why?

@@ -0,0 +1,35 @@
import process from 'node:process';

const wrapUnderSelectedFolder = function(shortName){
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

What is this for? Looks like you are wanting to see the full path?

}
}

export const openBrowser = function (url) {
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Very nice cross platform browser opening!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants