Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
83 changes: 57 additions & 26 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,42 +1,73 @@
A beautiful documentation starter kit.
# Dok: A beautiful Markdown docs starter kit

### Projects and versions
You can host multiple projects and manage different versions for each project. This is handled through the releases collection. To add a new project or version, simply create a new entry in the collection and configure the required fields.
Dok is a best-selling, modern documentation starter kit for Statamic. With powerful Markdown authoring tools, an extensible theme system, and ready-to-use frontend UI components - Dok lets you skip the groundwork, giving you a solid, production-ready foundation from day one.

### Statamic as a content source
Wanna just write markdown directly to Statamic? Yup, you can do that.
Some of Doks biggest features:
- Unlimited projects & unlimited releases/versions
- Statamic tags to get release & project information
- Ships with 7 ready-made themes
- Create new themes by changing as little as six CSS variables
- Build for exceptional perfoamnce
- Accessible
- Write markdown in Statamic
- Sync markdown from GitHyub
- Modern tools, AlpineJS & Tailwind v4
- Frontend UI components (fields, selects, toggles etc)
- Blade for components
- Author new components for use in Markdown without ever having to create a CommonMark extension with Component Binding.
- Phosphor for icons (all styles included!)
- Laravel Precognition & form templates included

### GitHub as a content source
If you'd like to host your documentation within a project repository to keep everything centralized, Dok makes the process simple. All you need is a GitHub Personal Access Token and a small update to your configuration file. Once that's done, you can easily link entries to their corresponding resource paths.
## Projects & Versions
Host unlimited projects and manage unlimited releases for each project. Easily create new projects or releases with a simple `dok:create:project` or `dok:create:release` command.

Content is linked to the Entry using a Computed Value.
## Markdown
Some of the best features of Dok are in it's flexible markdown authoring features.

### Styling
Dok comes with a light and dark theme, along with a full set of custom typography styles all using **Tailwind v4**. This means there is **no Tailwind configuration file**, just CSS files. Yay 🎉.
Alongside the components and extensions Dok ships with, it also includes a powerful feature called Component Binding. This allows you to use entirely new components directly in Markdown—without ever needing to create a CommonMark extension. With nothing more than a simple configuration change and a Blade file, you’re good to go.

### Browser support
Dok supports the latest versions of all major browsers. We use progressive enhancement where possible.
Dok ships with:

### Compiling Assets
By default, we use a simple Vite configuration that comes with every new Statamic site when using the CLI tool so you should feel right at home.
- **Code Group Extension**

`npm run dev` - Watches your content, rebuilds, and refreshes your browser so you can instantly see the changes.
The Code Group extension transforms your code blocks, bringing dynamic features like custom titles, collapsible blocks, tabbed content, and a copy code button. You can even control the markup by editing the Blade file!

`npm run build` - Build for production
- **Table Wrapping**

We all know tables are not fun to work with.. this extensions wraps your tables in a little extra markup, making tables that little bit better to style again.

## Installation
- **Lead Text**

**Installing with Statamic CLI (recommended)**
Lead text for (usually) below your main heading.

Get up and running in an instant with the Statamic CLI tool. This will install a fresh Statamic instance with Dok installed.
- **Hints**

```bash
statamic new mysite fawnsoftware/dok
```
Add note, tip, important, caution, warning hints to your markdown.

**Installing into an existing site**
```bash
php please starter-kit:install fawnsoftware/dok
```
- **Cards**

Add a simple card for navigation, or to just highlight some stuff a bit differently.

- **Accordion**

Just like the musical instrument, it folds.


## Content
Wanna just write markdown directly to Statamic? Yup, you can do that!

You can also import Markdown from GitHub using the built in utility or command. All you need is a Personal Access Token and a small update to your configuration file. Once that's done, you can link entries to their corresponding resource paths.

## Themes
Just six CSS variables control almost the entire site’s color system, making themes effortless to create and maintain. Dok ships with seven built-in themes that you can use as-is, remove, or tweak to your liking.

## Tags
Dok makes it easy to get information about your projects and releases with custom built-in tags. Learn more in the [docs](https://dok.fawnsoftware.com/dok/3.x/tags).

## Browser support
Dok supports the latest versions of all major browsers. Progressive enhancements are used where possible.

---

## Learn more
You can learn more about Dok by visiting the [documentation](https://dok.fawnsoftware.com/dok/3.x). This site also serves as the demo, and is even exactly what you'll see when you install Dok yourself!
36 changes: 20 additions & 16 deletions export/content/collections/dok_3x/installation.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,36 +8,40 @@ updated_at: 1741264233
# Installation

:::lead
Learn how to install Dok via the CLI or by installing into a new site.
Learn how to install Dok via the CLI or by installing into an existing site.
:::

---

:::caution title="Dok only supports ^6.0.0-beta4 installations"
Dok has been updated and released to support the v6.0 beta. This should cause minimal impact, but if you are installing from `statamic new my-site fawnsoftware/dok`, things won't work as you imagined.
**Installing Dok**

**Read the guide below to install into the latest beta.**
:::


Install via the cli as normal:
:::codegroup
{title="New site (Recommended)"}
```
statamic new mysite fawnsoftware/dok
```

```shell
statamic new my-site fawnsoftware/dok
{title="Existing site"}
```
php please starter-kit:install fawnsoftware/dok
```
:::/codegroup

:::note
You may get the error `Unknown searchable [content]`. You can safely ignore this as the config is for a v6 installation which we'll install next.
:::important
Requires the [Statamic CLI tool](https://github.com/statamic/cli) if you're installing a new site via the `statamic` command.
:::

Navigate to your newly created site in your terminal and require the latest Statamic beta:

**After Installation**
Run the initial build process. Installing the package dependencies and building the control panel assets.

```shell
composer require statamic/cms:^6.0@beta --with-all-dependencies
npm i && npm run cp:build
```

You're now ready to get started! But first, you'll need to install the node packages, build the control panel assets, and run your dev server:
You can then run your dev server:

```shell
npm i && npm run cp:build && npm run dev
npm run dev
```