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

Mardown converter endpoint #488

Merged
merged 3 commits into from
Dec 12, 2024
Merged

Mardown converter endpoint #488

merged 3 commits into from
Dec 12, 2024

Conversation

lebaudantoine
Copy link
Contributor

Allow backend service to convert markdown content in yjs one using a nodejs microservice bootstrapped by @AntoLC for collaboration purpose.

Blocked by #472

Please check my commits;

@lebaudantoine lebaudantoine changed the base branch from main to pod-yjs-direct-auth December 10, 2024 16:59
@AntoLC AntoLC force-pushed the pod-yjs-direct-auth branch from 0f9399b to a109366 Compare December 11, 2024 09:31
@lebaudantoine lebaudantoine marked this pull request as draft December 11, 2024 09:32
@AntoLC AntoLC force-pushed the pod-yjs-direct-auth branch from a109366 to 1e5976e Compare December 11, 2024 10:16
Copy link
Contributor

@AntoLC AntoLC left a comment

Choose a reason for hiding this comment

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

It seems good, I didn't try it though.
We will split server.test.ts and server.ts to make it more readable and maintainable, but let's do it in another PR.

Base automatically changed from pod-yjs-direct-auth to main December 11, 2024 13:54
@lebaudantoine lebaudantoine force-pushed the mardown-converter branch 3 times, most recently from f412e61 to c0db9e7 Compare December 12, 2024 12:47
@lebaudantoine lebaudantoine marked this pull request as ready for review December 12, 2024 12:48
@lebaudantoine lebaudantoine enabled auto-merge (rebase) December 12, 2024 12:59
Needed dependencies to mimic frontend code when generating a
document from a markdown string.

Will be used in the upcoming commits.
Add utility function to convert BitArray to Base64 string.
This is required for creating Base64-encoded documents,
as the frontend do.
This code is quite poor. Sorry, I don't have much time working
on this feature. However, it should be functional.

I've reused the code we created for the Demo with Kasbarian.
I've not tested it yet with all corner case. Error handling
might be improved for sure, same for logging.

This endpoint is not modular. We could easily introduce options
to modify its behavior based on some options. YAGNI

I've added bearer token authentification, because it's unclear
how this micro service would be exposed. It's totally not required
if the microservice is not exposed through an Ingress.
@qbey qbey disabled auto-merge December 12, 2024 13:33
@lebaudantoine lebaudantoine merged commit 5014443 into main Dec 12, 2024
16 checks passed
@lebaudantoine lebaudantoine deleted the mardown-converter branch December 12, 2024 13:37
@AntoLC AntoLC added the y.js label Jan 3, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants