GithubHelp home page GithubHelp logo

robertdigital / letsmarkdown.com Goto Github PK

View Code? Open in Web Editor NEW

This project forked from cveinnt/letsmarkdown.com

0.0 1.0 0.0 17.9 MB

๐Ÿ‘จโ€๐Ÿ’ป๐Ÿ‘ฉโ€๐Ÿ’ป Write Markdown. Together.

Home Page: https://letsmarkdown.com

License: MIT License

Shell 0.11% JavaScript 0.55% Rust 33.27% TypeScript 56.26% CSS 5.98% HTML 2.63% Dockerfile 1.20%

letsmarkdown.com's Introduction

๐Ÿ‘จโ€๐Ÿ’ป๐Ÿ‘ฉโ€๐Ÿ’ป LetsMarkdown.com

Fast, minimal web editor that makes markdown editing collaborative and accessible to everyone.


LetsMarkdown.com

Motivation

> I want to edit markdown files with my friends, but sending/resending files, changing viewing access, version control, and previewing are just too much work.

> ๐Ÿ’ก why not create a google doc for collaborative markdown editing, without having to log into Google, change view/edit access, worry about previewing the file, etc?

> Voilร , after hours of laborious coding, LetsMarkdown.com is born!

Features

  • Live collaborative markdown editing and preview
  • VSCode-like editor with support for command palette (syntax highlighting, autocomplete, editor themes...)
  • Minimal setup with no login required - say goodbye to malicious trackers and privacy invasions
  • Efficient backend built with Rust and WebAssembly
  • Dark mode (duh)
  • Emoji support with shortcuts enabled
  • (Upcoming) cursors tracking, synced scrolling, subscript/footnote/insert support, and more

Tech Stack

  • Frontend: React.js (TypeSript), Vite.js, Chakra UI
    • Editor & markdown preview: Monaco, mardown-it.js, highlight.js
  • Backend: Rust, WebAssembly, Node.js
  • Deployment & hosting: Docker, DigitalOcean
  • CI/CD: Github Action
  • Formatting: Prettier, Rustfmt
  • Design & prototyping: Figma

Development Info

This application is built using a backend operational transformation control server written in Rust (based on Rustpad), and a frontend written in TypeScript using React.js.

The backend server supports real-time collaborative editing sessions, and the frontend offers a collaborative text editor with built-in markdown syntax highlighting and auto-completion. These parts of the application are connected via WebSocket communication.

For markdown previewing, I used the markdown-it.js library to dynamically render the markdown file. To style the markdown file, I also created a custom markdown.css stylesheet.

To develop this application locally, you need to:

First, install Rust, wasm-pack, and Node.js. Verify your installation with:

rustup -V && wasm-pack -V && npm -v

Then, build the WebAssembly part of the app:

wasm-pack build --target web letsmarkdown-wasm

After that, install the dependencies for the React application:

npm install

Next, you can compile and run the backend web server:

cargo run

While the backend is running, open another shell and run the following command to start the frontend dev server.

npm run dev

This command will open a browser window to http://localhost:3000, with hot reloading enabled on saved changes.

Deployment

LetsMarkdown.com is distributed as a single 12 MB Docker image, which is built automatically from the Dockerfile in this repository. You can pull the latest version of this image from Docker Hub. It has multi-platform support for linux/amd64 and linux/arm64.

docker pull cveinnt/letsmarkdown

(You can also manually build this image with docker build -t rustpad . in the project root directory.) To run locally, execute the following command, then open http://localhost:3030 in your browser.

docker run --rm -dp 3030:3030 cveinnt/letsmarkdown

I deploy a public instance of this image with DigitalOcean App Platform.

Contributing

This project is still in a very early phase. If you're interested in adding new features or fixing bugs, please reach out to me by creating a GitHub issue!

I plan to integrate this repository continuously, and the code base already accounts for things like code style (Prettier, Rustfmt) and build success (Docker). The current state of the main branch is continuously deployed to the production web server at LetsMarkdown.com.

Credits

LetsMarkdown.com is inspired by composing.studio, which is based on Rustpad.


All code is licensed under the MIT license.

letsmarkdown.com's People

Contributors

cveinnt avatar needlesslygrim avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.