Detalhes do pacote

@honkit/internal-test-utils

honkit43MIT6.0.3

Internal utility for testing.

readme (leia-me)

HonKit

HonKit is building beautiful books using GitHub/Git and Markdown.

HonKit Screenshot

Documentation and Demo

HonKit documentation is built by HonKit!

Quick Start

Installation

The best way to install HonKit is via NPM or Yarn.

$ npm init --yes
$ npm install honkit --save-dev

⚠️ Warning:

  • If you have installed honkit globally, you must install each plugins globally as well
  • If you have installed honkit locally, you must install each plugins locally as well

We recommend installing honkit locally.

Create a book

HonKit can set up a boilerplate book:

$ npx honkit init

If you wish to create the book into a new directory, you can do so by running honkit init ./directory

Preview and serve your book using:

$ npx honkit serve

Or build the static website using:

$ npx honkit build

You can start to write your book!

For more details, see HonKit's documentation.

Docker support

Honkit provide docker image at honkit/honkit.

This docker image includes built-in dependencies for PDF/epub.

docker pull honkit/honkit
docker run -v `pwd`:`pwd` -w `pwd` --rm -it honkit/honkit honkit build
docker run -v `pwd`:`pwd` -w `pwd` --rm -it honkit/honkit honkit pdf

For more details, see docker/.

Usage examples

HonKit can be used to create a book, public documentation, enterprise manual, thesis, research papers, etc.

You can find a list of real-world examples in the documentation.

Features

Fork of GitBook

HonKit is a fork of GitBook (Legacy). GitBook (Legacy) is deprecated and an inactive project.

HonKit aims to smooth the migration from GitBook (Legacy) to HonKit.

Compatibility with GitBook

  • Almost all plugins work without changes!
  • Support gitbook-plugin-* packages
    • You should install these plugins via npm or yarn
    • npm install gitbook-plugin-<example> --save-dev

Differences with GitBook

  • Node.js 14+ supports
  • Improve build/serve performance
    • honkit build: use file cache by default
    • honkit serve: 28.2s → 0.9s in examples/benchmark
    • Also, support --reload flag for force refresh
  • Improve plugin loading logic
    • Reduce cost of finding honkit-plugin-* and gitbook-plugin-*
    • Support honkit-plugin-* and @scope/honkit-plugin-* (GitBook does not support a scoped module)
  • Remove install command
    • Instead of it, just use npm install or yarn install
  • Remove global-npm dependency
    • You can use HonKit with another npm package manager like npm or yarn
  • Update dependencies
    • Upgrade to nunjucks@2, highlight.js etc...
    • It will reduce bugs
  • TypeScript
    • Rewritten by TypeScript
  • Monorepo codebase
    • Easy to maintain
  • Docker support

Migration from GitBook

Replace gitbook-cli with honkit.

npm uninstall gitbook-cli
npm install honkit --save-dev

Replace gitbook command with honkit command.

  "scripts": {
-    "build": "gitbook build",
+    "build": "honkit build",
-    "serve": "gitbook serve"
+    "serve": "honkit serve"
  },

After that, HonKit just works!

Examples of migration:

Benchmarks

honkit build benchmark:

Licensing

HonKit is licensed under the Apache License, Version 2.0. See LICENSE for the full license text.

HonKit is a fork of GitBook (Legacy). GitBook is licensed under the Apache License, Version 2.0.

Also, HonKit includes bignerdranch/gitbook works.

Sponsors

Deploys by Netlify

changelog (log de mudanças)

Change Log (Deprecated)

See Releases on GitHub for the newest releases with notable changes provided.

See Conventional Commits for commit guidelines.

4.0.6 (2023-03-26)

Note: Version bump only for package honkit-root

4.0.5 (2023-03-26)

Note: Version bump only for package honkit-root

4.0.4 (2022-10-22)

Note: Version bump only for package honkit-root

4.0.3 (2022-10-22)

Bug Fixes

4.0.2 (2022-10-19)

Bug Fixes

  • honkit: fix missing --flat for cpy 9+ (#301) (90edf03)

4.0.1 (2022-10-18)

Bug Fixes

4.0.0 (2022-08-28)

Bug Fixes

Features

  • publish: multiple docker images per node.js version (#289) (6995c16)

BREAKING CHANGES

Probably, Current HonKit still work on Node.js 12, but it will be broken in minor updates.

3.7.5 (2022-07-14)

Bug Fixes

  • honkit: hokit server should not watch node_modules/** changes (#277) (982d649)

3.7.4 (2022-06-21)

Bug Fixes

  • honkit: make honkit parse work for multi lang book (#271) (83f7597)

3.7.3 (2022-05-28)

Bug Fixes

  • theme-default: prevent to replace html/head/body as strings (#266) (3d9392b)

3.7.2 (2022-05-28)

Bug Fixes

3.7.1 (2022-01-17)

Note: Version bump only for package honkit-root

3.7.0 (2022-01-17)

Features

Performance Improvements

3.6.23 (2021-11-04)

Bug Fixes

  • honit: remove spawn-cmd (#230) (9640e65)
  • honkit: add typing to encode{Navigation,Progress} (60895ec)
  • honkit: add typing to encodeConfig (dba0a66)
  • honkit: add typing to encodePage (63589ef)
  • honkit: Replace newlines with white space in pdf headers + footers (#237) (ebe4d60)

3.6.22 (2021-10-02)

Note: Version bump only for package honkit

3.6.21 (2021-09-16)

Bug Fixes

  • add ts-expect-error to wrong typing (4a08d02)
  • honkit: change pdf margin options (#223) (7ffa130), closes #221

3.6.20 (2021-04-14)

Bug Fixes

  • theme-detault: Remove Console Log for Page Changes (#203) (5836f23)

3.6.19 (2021-03-27)

Bug Fixes

  • honkit-plugin-highlight: fix highlight.js warning (#200) (4433488)

3.6.18 (2021-03-27)

Bug Fixes

  • theme-default: fix Uncaught TypeError when click a page (#196) (349aae6)

3.6.17 (2021-02-15)

Bug Fixes

  • honkit: use ^ semver for deps (#185) (f0d1ef9)
  • hontkit: update to urijs@^1.19.6 (ff00810)

3.6.16 (2020-12-15)

Note: Version bump only for package honkit

3.6.15 (2020-12-05)

Note: Version bump only for package honkit

3.6.14 (2020-11-29)

Note: Version bump only for package honkit

3.6.13 (2020-11-17)

Bug Fixes

  • honkit: browser print layout in default theme (#159) (672cb9c)

3.6.12 (2020-11-13)

Note: Version bump only for package honkit

3.6.11 (2020-11-10)

Note: Version bump only for package honkit

3.6.10 (2020-11-10)

Bug Fixes

  • default-theme: move restoring sidebar logic to critical path (aa7a598)
  • honkit/theme-default: fix first scroll position (4fb9cd3)
  • theme-default: add .honkit-cloak (77feada)
  • theme-default: fix blank page on mobile (6401745)
  • theme-default: fix blank page on mobile (1200422)
  • theme-default: fix restore login when disable sidebar (8445459)

3.6.9 (2020-11-10)

Bug Fixes

  • default-theme: move restoring sidebar logic to critical path (aa7a598)
  • honkit/theme-default: fix first scroll position (4fb9cd3)
  • theme-default: add .honkit-cloak (77feada)
  • theme-default: fix restore login when disable sidebar (8445459)

3.6.8 (2020-10-22)

Bug Fixes

  • honkit: call "page" and "page:before" if honkit has the cache (3742225)

3.6.7 (2020-10-22)

Bug Fixes

  • honkit: call "page" and "page:before" if honkit has the cache (3742225)

3.6.6 (2020-09-05)

Features

  • docker: add ebook-convert installation (d7b63ed)

3.6.5 (2020-08-31)

Bug Fixes

  • honkit: fix empty publish (92aabd6)

3.6.4 (2020-08-31)

Bug Fixes

  • docker: use latest as default (ef7f0f1)

3.6.3 (2020-08-31)

Bug Fixes

  • change versionup script (7ed4bb3)

Features

  • docker: add basic Dockerfile (4a56826)

3.6.2 (2020-08-31)

Bug Fixes

  • change versionup script (7ed4bb3)

Features

  • docker: add basic Dockerfile (4a56826)

3.6.1 (2020-08-15)

Bug Fixes

  • honkit: fix next/prev button on anchor article (#110) (fc54b71)

3.6.0 (2020-08-06)

Features

3.5.5 (2020-08-02)

Bug Fixes

  • honkit/html: fix cheerio versioning (7849651)
  • markdown-legacy: use @honkit/html (96a22df)

3.5.4 (2020-08-01)

Bug Fixes

3.5.3 (2020-07-31)

Bug Fixes

  • honkit: return if src is null or undefined in resolveImages (#103) (bedbf56)

3.5.2 (2020-07-05)

Bug Fixes

  • markdown-legacy: normalize some characters for kramed's annotate function (#88) (29424f3)
  • theme-default: include index.js to files (#90) (2ac7029)

3.5.1 (2020-07-04)

Bug Fixes

  • honkit: use @honkit/markdown-legacy instead of @honkit/markdown (e8549d5)
  • markdown-legacy: fix new line encoding on Windows (a5fa2fb)

Reverts

  • Revert "Enable highlight in browser build" (dc8f286)

3.5.0 (2020-07-02)

Features

3.4.1 (2020-06-29)

Bug Fixes

  • honkit: fix to load @scope/honkit-plugin-name (#69) (5c93524)

3.4.0 (2020-06-27)

Features

3.3.11 (2020-06-27)

Bug Fixes

  • honkit: fix --reload options (bb5149f), closes #59
  • markdown: Do not force convert Indented CodeBlock to Fenced code blocks (#60) (ef55687)

3.3.10 (2020-06-20)

Bug Fixes

  • honkit: relax "gitbook" engine version check (d3850a9)

3.3.9 (2020-06-18)

Bug Fixes

  • theme-default: fix apple-touch-icon-precomposed-152.png name (7bb6516)

3.3.8 (2020-06-18)

Note: Version bump only for package honkit

3.3.7 (2020-06-18)

Note: Version bump only for package honkit

3.3.6 (2020-06-18)

Note: Version bump only for package honkit

3.3.5 (2020-06-18)

Note: Version bump only for package honkit

3.3.4 (2020-06-17)

Bug Fixes

  • honkit: disable confirm on copyDir (008d66f)
  • honkit: ignore symlink (662028a)
  • honkit: use Buffer.from instead of Buffer constructor (1d4fe84), closes #26
  • honkit: use lstat instead of stat (bbe0e41)
  • theme-default: fix ja translation (4f1a1ec)

3.3.3 (2020-06-16)

Bug Fixes

  • theme-default: add prepublish (8449f8b)
  • theme-default: add publishConfig (c5dfcb2)
  • theme-default: add publishConfig (8a6acec)

3.3.2 (2020-06-16)

Bug Fixes

  • honkit: / is os specific (2e28891)
  • honkit: support @honkit/honkit-plugin-theme-default as special (2adca8d)
  • honkit: validatePlugin (8a03bcb)
  • netlify: build before build (b2debc7)

Performance Improvements

  • honkit: refactor plugin loading (3e0d841)

3.3.1 (2020-06-15)

Bug Fixes

  • markdown: fix markdown parser (2a1d670)

3.3.0 (2020-06-14)

Bug Fixes

  • remove unused var (b23b372)
  • fs: no use util (2a9b299)
  • generate: Promise.all should handle array (7e59857)
  • remove install, <type> (fffe2d8)

Features

  • examples: add example (fb53dc8)
  • serve: support incremental build (88937fd)

Performance Improvements

Reverts

  • Revert "Enable highlight in browser build" (6e3df61)

3.2.2 (2016-10-01)

3.2.1 (2016-09-28)

3.2.0 (2016-07-11)

3.2.0-pre.1 (2016-07-05)

3.2.0-pre.0 (2016-06-30)

3.1.1 (2016-06-10)

3.1.0 (2016-06-06)

3.0.3 (2016-05-27)

3.0.2 (2016-05-25)

3.0.1 (2016-05-25)

3.0.0 (2016-05-20)

3.0.0-pre.15 (2016-05-12)

Reverts

  • Revert "Extend Book.getLanguageBook" (61956e0)

3.0.0-pre.14 (2016-05-10)

3.0.0-pre.13 (2016-05-06)

3.0.0-pre.12 (2016-05-04)

3.0.0-pre.11 (2016-05-03)

3.0.0-pre.10 (2016-05-02)

3.0.0-pre.9 (2016-04-19)

3.0.0-pre.8 (2016-04-14)

3.0.0-pre.7 (2016-04-11)

3.0.0-pre.6 (2016-04-08)

3.0.0-pre.5 (2016-03-07)

3.0.0-pre.4 (2016-03-07)

3.0.0-pre.3 (2016-03-02)

3.0.0-pre.2 (2016-02-29)

3.0.0-pre.1 (2016-02-26)

2.6.7 (2016-01-13)

2.6.6 (2015-12-16)

2.6.5 (2015-12-11)

2.6.4 (2015-12-02)

2.6.3 (2015-12-02)

2.6.2 (2015-11-25)

2.6.1 (2015-11-25)

2.6.0 (2015-11-25)

2.5.2 (2015-11-03)

2.5.1 (2015-10-27)

2.5.0 (2015-10-27)

2.5.0-beta.7 (2015-10-22)

2.5.0-beta.6 (2015-10-20)

2.5.0-beta.5 (2015-10-16)

2.5.0-beta.4 (2015-10-14)

2.5.0-beta.3 (2015-10-14)

2.5.0-beta.2 (2015-10-14)

2.5.0-beta.1 (2015-10-13)

2.4.3 (2015-10-01)

2.4.2 (2015-09-22)

2.4.1 (2015-09-18)

2.4.0 (2015-09-15)

2.3.3 (2015-09-10)

2.3.2 (2015-09-09)

2.3.1 (2015-09-08)

2.3.0 (2015-09-01)

2.2.0 (2015-07-28)

2.1.0 (2015-06-02)

2.0.4 (2015-05-28)

2.0.3 (2015-05-27)

2.0.2 (2015-05-02)

2.0.1 (2015-04-02)

2.0.0 (2015-03-25)

2.0.0-beta.5 (2015-03-17)

2.0.0-beta.4 (2015-03-17)

2.0.0-beta.3 (2015-03-12)

2.0.0-beta.2 (2015-03-11)

2.0.0-beta.1 (2015-03-11)

2.0.0-alpha.9 (2015-02-24)

2.0.0-alpha.8 (2015-02-14)

2.0.0-alpha.7 (2015-02-12)

2.0.0-alpha.6 (2015-02-06)

2.0.0-alpha.5 (2015-02-05)

2.0.0-alpha.4 (2015-02-04)

2.0.0-alpha.3 (2015-02-04)

2.0.0-alpha.2 (2015-02-04)

2.0.0-alpha.1 (2015-02-03)

1.5.0 (2014-12-17)

1.4.2 (2014-12-10)

1.4.1 (2014-11-30)

1.4.0 (2014-11-30)

1.3.4 (2014-11-25)

1.3.3 (2014-11-14)

1.3.2 (2014-11-14)

1.3.1 (2014-11-03)

1.3.0 (2014-11-01)

1.2.0 (2014-10-30)

1.1.1 (2014-10-13)

1.1.0 (2014-09-24)

1.0.3 (2014-09-05)

1.0.2 (2014-08-21)

1.0.1 (2014-08-20)

1.0.0 (2014-08-19)

0.7.1 (2014-08-08)

0.7.0 (2014-08-01)

0.6.3 (2014-07-30)

0.6.2 (2014-07-30)

0.6.1 (2014-07-23)

0.6.0 (2014-07-12)

0.5.6 (2014-06-24)

0.5.5 (2014-06-18)

0.5.4 (2014-06-17)

0.5.3 (2014-06-16)

0.5.2 (2014-06-07)

0.5.1 (2014-06-07)

0.5.0 (2014-06-03)

0.4.8 (2014-05-29)

0.4.7 (2014-05-26)

0.4.6 (2014-05-23)

0.4.5 (2014-05-21)

0.4.4 (2014-05-21)

0.4.3 (2014-05-18)

0.4.2 (2014-05-01)

0.4.1 (2014-04-29)

0.4.0 (2014-04-28)

0.3.2 (2014-04-27)

0.3.1 (2014-04-24)

0.2.4 (2014-04-20)

0.2.3 (2014-04-18)

0.2.2 (2014-04-17)

0.2.1 (2014-04-17)

0.2.0 (2014-04-14)

Reverts

  • Revert "Fix ebook and pdf generator" (d6d9223)

0.1.3 (2014-04-09)

0.1.2 (2014-04-07)

0.1.1 (2014-04-05)

0.1.0 (2014-04-03)

0.0.4 (2014-04-03)

0.0.3 (2014-04-02)

0.0.2 (2014-04-02)

0.0.1 (2014-04-01)