From 4d924387ce29b7938baf61fb35b1b54f94bc3e55 Mon Sep 17 00:00:00 2001 From: thePR0M3TH3AN <53631862+PR0M3TH3AN@users.noreply.github.com> Date: Thu, 10 Jul 2025 12:02:39 -0400 Subject: [PATCH] Add DocForge documentation site --- docs/config.yaml | 6 ++++++ docs/content/advanced/api/endpoints.md | 3 +++ docs/content/advanced/index.md | 3 +++ docs/content/customization/index.md | 3 +++ docs/content/customization/plugins.md | 13 +++++++++++++ docs/content/deployment/index.md | 9 +++++++++ docs/content/features/index.md | 8 ++++++++ docs/content/getting-started/01-install.md | 11 +++++++++++ docs/content/getting-started/02-build.md | 9 +++++++++ docs/content/getting-started/index.md | 3 +++ docs/content/index.md | 15 +++++++++++++++ docs/package.json | 11 +++++++++++ 12 files changed, 94 insertions(+) create mode 100644 docs/config.yaml create mode 100644 docs/content/advanced/api/endpoints.md create mode 100644 docs/content/advanced/index.md create mode 100644 docs/content/customization/index.md create mode 100644 docs/content/customization/plugins.md create mode 100644 docs/content/deployment/index.md create mode 100644 docs/content/features/index.md create mode 100644 docs/content/getting-started/01-install.md create mode 100644 docs/content/getting-started/02-build.md create mode 100644 docs/content/getting-started/index.md create mode 100644 docs/content/index.md create mode 100644 docs/package.json diff --git a/docs/config.yaml b/docs/config.yaml new file mode 100644 index 0000000..da16234 --- /dev/null +++ b/docs/config.yaml @@ -0,0 +1,6 @@ +site: + title: "DocForge Docs" + description: "Simple static docs." + +navigation: + search: true diff --git a/docs/content/advanced/api/endpoints.md b/docs/content/advanced/api/endpoints.md new file mode 100644 index 0000000..1c430a0 --- /dev/null +++ b/docs/content/advanced/api/endpoints.md @@ -0,0 +1,3 @@ +# API Endpoints + +If you expose APIs for your project, document them here. DocForge does not impose any format—just write Markdown. diff --git a/docs/content/advanced/index.md b/docs/content/advanced/index.md new file mode 100644 index 0000000..af20900 --- /dev/null +++ b/docs/content/advanced/index.md @@ -0,0 +1,3 @@ +# Advanced Topics + +Use this section for in-depth guides, such as API references or multi-version setups. diff --git a/docs/content/customization/index.md b/docs/content/customization/index.md new file mode 100644 index 0000000..8c7c5a5 --- /dev/null +++ b/docs/content/customization/index.md @@ -0,0 +1,3 @@ +# Customizing Your Site + +Site settings live in `config.yaml`. You can change the title, logo, colors, and enable features like analytics or multi-language support. diff --git a/docs/content/customization/plugins.md b/docs/content/customization/plugins.md new file mode 100644 index 0000000..6cee08c --- /dev/null +++ b/docs/content/customization/plugins.md @@ -0,0 +1,13 @@ +# Writing Plugins + +Create JavaScript modules in the `plugins/` directory. Export hook functions such as `onParseMarkdown` or `onPageRendered` to modify the build. + +Example: + +```js +module.exports = { + onPageRendered: async ({ html }) => { + return { html: html + '\n' }; + } +}; +``` diff --git a/docs/content/deployment/index.md b/docs/content/deployment/index.md new file mode 100644 index 0000000..9f23e80 --- /dev/null +++ b/docs/content/deployment/index.md @@ -0,0 +1,9 @@ +# Deployment + +DocForge sites output to the `_site/` folder. Host the contents on any static server. For Netlify, include a `netlify.toml` file: + +```toml +[build] + command = "npm run build" + publish = "_site" +``` diff --git a/docs/content/features/index.md b/docs/content/features/index.md new file mode 100644 index 0000000..5dde700 --- /dev/null +++ b/docs/content/features/index.md @@ -0,0 +1,8 @@ +# Features Overview + +DocForge automatically turns your Markdown files into a full documentation site with a responsive layout and search. + +* Sidebar navigation generated from folders +* Collapsible mobile menu and dark-mode switch +* Client-side search powered by Lunr.js +* Shortcodes for rich content (images, tabs, notes) diff --git a/docs/content/getting-started/01-install.md b/docs/content/getting-started/01-install.md new file mode 100644 index 0000000..77477b2 --- /dev/null +++ b/docs/content/getting-started/01-install.md @@ -0,0 +1,11 @@ +# Install DocForge + +1. Clone or download this repository. +2. Run `npm install` to install dependencies. +3. Start the local development server: + +```bash +npm run dev +``` + +The site will be available at `http://localhost:8080`. diff --git a/docs/content/getting-started/02-build.md b/docs/content/getting-started/02-build.md new file mode 100644 index 0000000..9dd3b77 --- /dev/null +++ b/docs/content/getting-started/02-build.md @@ -0,0 +1,9 @@ +# Build the Site + +When you're ready to generate the static files, run: + +```bash +npm run build +``` + +The output appears in the `_site/` folder. diff --git a/docs/content/getting-started/index.md b/docs/content/getting-started/index.md new file mode 100644 index 0000000..be90993 --- /dev/null +++ b/docs/content/getting-started/index.md @@ -0,0 +1,3 @@ +# Getting Started + +This section walks you through installing DocForge and creating your first site. diff --git a/docs/content/index.md b/docs/content/index.md new file mode 100644 index 0000000..7ebf5d5 --- /dev/null +++ b/docs/content/index.md @@ -0,0 +1,15 @@ +# DocForge Documentation + +Welcome to the official documentation for **DocForge**, a lightweight static site generator designed for "Read the Docs" style websites. + +## Quick Start + +```bash +npm install +npm run dev # start local server at http://localhost:8080 +npm run build # generate the _site/ folder +``` + +DocForge converts Markdown files inside a `content/` folder into a full documentation site with search, navigation, and responsive design. + +Check the **Getting Started** section to learn how to install and run DocForge locally. diff --git a/docs/package.json b/docs/package.json new file mode 100644 index 0000000..42abf53 --- /dev/null +++ b/docs/package.json @@ -0,0 +1,11 @@ +{ + "name": "docs", + "private": true, + "scripts": { + "dev": "eleventy --serve", + "build": "node node_modules/docforge/src/generator/index.js" + }, + "dependencies": { + "docforge": "^1.0.0" + } +} \ No newline at end of file