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

JTE/PKFE-46 #58

Merged
merged 12 commits into from
Sep 10, 2024
Merged

JTE/PKFE-46 #58

merged 12 commits into from
Sep 10, 2024

Conversation

justinnas
Copy link
Collaborator

Added file export functionality.

@justinnas justinnas added the enhancement New feature or request label Sep 9, 2024
@justinnas justinnas self-assigned this Sep 9, 2024
Copy link
Collaborator

@mantvydasdeltuva mantvydasdeltuva left a comment

Choose a reason for hiding this comment

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

Great work! Minor oversights

@@ -158,6 +157,30 @@ export const FileTreeItemContextMenu: React.FC<FileTreeItemContextMenuProps> = (
filesHistoryStateUpdate(undefined, { id: item.id, label: item.label, type: item.fileType || FileTypes.FILE });
};

const handleExport = async () => {
Copy link
Collaborator

Choose a reason for hiding this comment

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

use hook useCallback to memorize functions to reduce recreation every render

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

Good idea

return response

except FileNotFoundError as e:
logger.error("FileNotFoundError: %s while accessing %s", e, user_workspace_dir)
Copy link
Collaborator

Choose a reason for hiding this comment

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

edit everywhere where logger and console feedback: accessing -> exporting

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

Great catch

Copy link
Collaborator

@mantvydasdeltuva mantvydasdeltuva left a comment

Choose a reason for hiding this comment

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

Great work!

@justinnas justinnas merged commit 43db108 into main Sep 10, 2024
0 of 3 checks passed
@justinnas justinnas deleted the JTE/PKFE-46 branch September 10, 2024 21:31
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants