-
Notifications
You must be signed in to change notification settings - Fork 2.3k
Fix webview in dev mode #7044
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
Fix webview in dev mode #7044
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thank you for your contribution! I've reviewed the changes and found a critical issue that needs attention. The approach of creating a proxy file while removing the dependency will cause build failures.
@@ -0,0 +1,8 @@ | ||
import { CloudUserInfo, OrganizationAllowList, ShareVisibility } from "@roo-code/cloud" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This file imports from @roo-code/cloud
, but the PR removes this package from dependencies in package.json. This will cause a build failure since the package won't be available.
Is this intentional? If the goal is to fix the webview in dev mode, this approach will just move the error to a different location rather than fixing it.
Consider either:
- Keeping
@roo-code/cloud
as a dependency if it's still needed - Or fully migrating these types to local definitions if the goal is to remove the external dependency
"@radix-ui/react-slot": "^1.1.2", | ||
"@radix-ui/react-tooltip": "^1.1.8", | ||
"@roo-code/cloud": "^0.13.0", | ||
"@roo-code/types": "workspace:^", |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
You're removing @roo-code/cloud
from dependencies here, but the new src/shared/cloud.ts
file still imports from this package. This seems contradictory and will cause the build to fail.
Could you clarify the intended approach? Are you trying to move the cloud package to a different location, or completely remove the dependency?
} from "@roo-code/types" | ||
import { type OrganizationAllowList, ORGANIZATION_ALLOW_ALL } from "@roo-code/cloud" | ||
|
||
import { type OrganizationAllowList, ORGANIZATION_ALLOW_ALL } from "@roo/cloud" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The import path change from @roo-code/cloud
to @roo/cloud
looks good and follows the TypeScript path mapping. However, this will only work if the underlying dependency issue is resolved (see my comment on src/shared/cloud.ts).
Important
Fix webview in development mode by updating dependencies, imports, and build configurations.
@roo-code/cloud
dependency fromwebview-ui/package.json
.knip.json
to include../src/shared/*.ts
inwebview-ui
project.@roo-code/cloud
to@roo/cloud
in multiple files includingAccountView.tsx
,ShareButton.tsx
, andApiConfigManager.tsx
.@roo-code/cloud
package linking fromlink-packages.js
.cloud.ts
tosrc/shared/
.vscode.ts
mock fromwebview-ui/src/__mocks__/
.external: ["vscode"]
fromrollupOptions
invite.config.ts
.This description was created by
for 4d7b94f. You can customize this summary. It will automatically update as commits are pushed.