Skip to content

puni9869/blank-editor

Folders and files

NameName
Last commit message
Last commit date

Latest commit

Β 

History

112 Commits
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 

App Icon

Blank Editor

A minimal, premium-grade AI-powered text editor for clean writing and intelligent editing.

Contributors Issues Pull Requests License Last Commit


✨ Features

🧠 AI-Powered Writing Assistance

  • Smart content refinement and clarity improvement.
  • Built with TipTap + ProseMirror
  • Formatting: bold, italic, underline, strikethrough, highlight
  • Headings (H1-H5), bullet/ordered lists, blockquote, code block, divider
  • Text alignment controls: left, center, right, justify
  • Journal block support

πŸ’Ύ Note Persistence

  • Auto-save editor content and title in localStorage
  • Save and manage notes in IndexedDB
  • Search and reopen saved notes from the "All Notes"

⚑ Productivity

  • Keyboard shortcuts for save, notes, fullscreen, and quick new page
  • Fullscreen mode
  • Minimal interface with responsive layout
  • Toast feedback for editor actions

πŸ“¦ Standalone Binary

  • Single self-contained Go binary with embedded frontend and assets
  • No external files or dependencies needed at runtime
  • Configurable via CLI flags or environment variables
  • Graceful shutdown, security headers, smart caching

Demo

Check out the live demo here: Blank Editor Demo

Screenshots

Blank Editor Screenshot 8 Blank Editor Screenshot 4 Blank Editor Screenshot 1 Blank Editor Screenshot 2 Blank Editor Screenshot 3


Installation

Prerequisites

  • Node.js >= 18.18.0
  • pnpm (via corepack or npm install -g pnpm)
  • Go >= 1.26 (for the standalone server)

Setup

git clone https://github.com/puni9869/blank-editor.git
cd blank-editor
corepack enable
pnpm install

If corepack is unavailable, install pnpm globally with npm install -g pnpm.


Usage

Frontend Development

pnpm dev              # Vite dev server at http://localhost:5173
make watch-frontend   # Same, via Makefile

Build Frontend

pnpm build            # Outputs to dist/
pnpm preview          # Preview the production build

Go Server (Standalone Binary)

The Go server embeds the frontend build (dist/) and static assets (assets/) into a single self-contained binary.

make build            # Builds frontend + Go binary β†’ build/blank-editor
make production       # Same, with CGO_ENABLED=0, trimpath, and git version tag
make run              # Build and start the server

Run the binary directly:

./build/blank-editor start                        # http://0.0.0.0:8080
./build/blank-editor start --port 3000            # Custom port
./build/blank-editor start --host 127.0.0.1       # Bind to localhost only

All flags are also configurable via environment variables:

Flag Env Var Default
--host BLANK_EDITOR_HOST 0.0.0.0
--port BLANK_EDITOR_PORT 8080
--read-timeout BLANK_EDITOR_READ_TIMEOUT 15s
--write-timeout BLANK_EDITOR_WRITE_TIMEOUT 15s
--idle-timeout BLANK_EDITOR_IDLE_TIMEOUT 60s
--shutdown-timeout BLANK_EDITOR_SHUTDOWN_TIMEOUT 10s

Format and Lint

pnpm format       # Prettier formatting
pnpm lint         # ESLint checks
pnpm lint:fix     # Auto-fix linting issues
make fmt          # Go formatting
make vet          # Go vet
make lint         # golangci-lint

Project Structure

β”œβ”€β”€ assets/              # Static assets (favicons, robots.txt, sitemap)
β”œβ”€β”€ cmd/                 # Go CLI entry point and commands
β”‚   β”œβ”€β”€ main.go
β”‚   └── command/
β”œβ”€β”€ frontend/            # Frontend source (vanilla JS + TipTap)
β”‚   β”œβ”€β”€ components/
β”‚   β”œβ”€β”€ config/
β”‚   β”œβ”€β”€ css/
β”‚   β”œβ”€β”€ db/
β”‚   β”œβ”€β”€ lib/
β”‚   β”œβ”€β”€ plugins/
β”‚   └── types/
β”œβ”€β”€ server/              # Go HTTP server (routes, middleware, lifecycle)
β”‚   β”œβ”€β”€ routes.go
β”‚   β”œβ”€β”€ middleware.go
β”‚   └── server.go
β”œβ”€β”€ pkg/                 # Shared Go packages (logger, render)
β”œβ”€β”€ templates/           # Go HTML templates
β”œβ”€β”€ embed.go             # Embeds dist/ and assets/ into the binary
β”œβ”€β”€ index.html           # Frontend entry point
└── vite.config.js       # Vite build configuration

Deployment

GitHub Pages

Pushes to main automatically build and deploy the frontend to GitHub Pages via the static.yml workflow.

Live demo: https://puni9869.github.io/blank-editor/

Go Binary Releases

Tagging a release (v*) triggers the release.yml workflow, which builds cross-platform binaries (linux/darwin/windows, amd64/arm64) and uploads them as GitHub release assets.


Contributing

We ❀️ contributions! See CONTRIBUTING.md for guidelines.

  • Fork the repo
  • Create a new branch (feature/your-feature)
  • Submit pull requests for bug fixes or new features
  • Ensure pnpm lint passes before submitting

Reporting Issues

If you find a bug or have a feature request, please open an issue on GitHub: Issues


License

This project is licensed under the MIT License β€” see LICENSE for details.


Contributors

Thanks to all the wonderful contributors ❀️