Pencil is a powerful static documentation website generator that works on Markdown.
What can it do?
Pencil allows you to write content in Markdown, which has a very powerful and easy to learn markup syntax. You can quickly start creating your website without much code.
Pencil will automatically create the required files for your website, which are ready to be deployed to services like Netlify, GitHub Pages.
Static site generation
- Minified files
- SEO friendly
- Integrate external files
Built-in markdown plugins
- Table of contents
- Anchored Headings
- Code highlighting
- YouTube player embed
- Control theme color
- Dark theme 🕶
- Custom plugins support
Pencil site can be created quickly using the CLI tool. Make sure you have recent LTS version of Node.js installed. Follow the commands below:
npm install -g @pencil/corepencil init# follow steps shown in CLI
Installing dependencies via
npm installis not necessary if CLI is globally installed.
Following commands must be followed to setup Pencil development environment.
git clone https://github.com/blenderskool/pencilcd pencilnpm installnpm run dev
By default, the dev server opens at port
3000 with the playground.
Playground is where you can test the code and make live changes to it.
Pencil follows the following directory structure,
src- Contains the source code.
core- Core modules that are used.
functions- Contains the code for the builder.
templates- Template files that define the structure, design and basic functionality of documentation website.
utils- Helper functions used extensively in functions.
playground- A sample documentation website setup to test Pencil features during development.
bin- Contains the scripts for the CLI.
Make sure you create a fork of this repository before you start contributing.
git clone <your-forked-repo>cd <your-forked-repo>npm installnpm run devgit checkout -b some-fix# make changes to the codegit commit -m "Your commit message"git push origin some-fix
Use the playground to test your code. Do not commit changes made in the
Once you are done with the changes, you can open a pull request to
Pencil is MIT Licensed