UNPKG

wikic

Version:

a simple static site generator

100 lines (80 loc) 2.39 kB
root: . # root dir of files, relative to `wikic.cwd` # `wikic.cwd` 's default value is process.cwd() # initialize wikic with `new Wikic('path/to')` or `wikic.setup('path/to') to set wikic.cwd docsPath: _notes # dir where documents place, relative to `root` layoutPath: _layouts # dir where nunjunks layouts place, relative to `root` publicPath: docs # site destination, relative to `root` title: '' # title of site baseurl: '' # site base URL port: 4000 # server port watch: false # whether to build when file changes server: null # Function(config, publicPath) | string (module id) excludes: [] # directories and files to ignore for both public and watch, support glob, relative to `root` publicExcludes: [] watchExcludes: [] typeMap: {} # map from dirname to typeName typeNameTitleCase: true page: # default page config layout: default # default layout name toc: true # enable/disable table of content logger: # https://github.com/winstonjs/winston#logging-levels file: warn console: verbose # toc: # # See https://github.com/jonschlinkert/html-toc#options # selectors: 'h1, h2' # # minLength: 0 # # min length of headings to create toc # # addID: true # parentLink: false # # id: '#toc' # # selector of toc container # # # Following options are available in `wikic.config.js` but not in `_config.yml` # # because JavaScript's function is not available in YAML. # slugger: # Function # anchorTemplate: # Function # markdownIt: # # See https://github.com/markdown-it/markdown-it#init-with-presets-and-options # # See lib/filters/markdown.js # html: true # linkify: true # typography: true # highlight: # Function, use highlight.js # # # wikic only opts here: # # disableBuiltInPlugins: false, # # whether to disable default plugins loaded by wikic, such as `markdown-it-prism` # # getInstance: #Function # # will be called with markdownIt instance, we can load plugins here # suites: [] # Array<string(module id)|object|function(config,Wikic)> # watchHandlers: # # values are matchers in https://www.npmjs.com/package/anymatch # # see defaults in lib/wikic/index.js watch() # # setupAndBuild: #<matchers> # # run wikic.setup().build() # # which receives new config and then rebuild # # build: #<matchers> # run wikic.build() # buildStaticFile: #<matchers> # build the static file which changed