Code Monkey home page Code Monkey logo

webdoc-template's Introduction

@pixi/webdoc-template

This template is used to generate the standalone PixiJS API documentation and was based on pixi-jsdoc-template.

For usage, see webdoc.

Working with docs generation

  • Docs generation triggers the publish.js script which will generate and manipulate all the doc nodes that are then used to build out the docs HTML files - based on the templates within the tmpl directory. The .tmpl template files can be edited directly and will be reflected on rebuild.
  • Static resources within the static directory will also be copied over into the directory where the compiled HTML files go, which include the scripts and the styles.
  • To iterate on the publish.js, the main.js script and the main.css, please refer to the src directory which hold all the source files for these 3 compiled files.
    • src/index.js is the entry point for the compilation of publish.js while src/static/index.js is for main.js that gets loaded on the client.
    • src/static/styles/index.scss is the entry point for the compilation of main.css that also gets loaded alongside the client from within the HTML files.
  • Once altered, run npm run build to kick start the compilation. npm run watch is also available for re-compilation on changes.

webdoc-template's People

Contributors

achamas-playco avatar bbazukun123 avatar bigtimebuddy avatar dependabot[bot] avatar shukantpal avatar supersodasea avatar zyie avatar

Stargazers

 avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

webdoc-template's Issues

UnhandledPromiseRejectionWarning: Error: Cannot find module 'jsdoc/src/filter'

Hello, I'm trying to migrate to webdoc from pixi-jsdoc-template

I my webdoc config I have

"templates": {
    "default": {
          "staticFiles": {
              "include": [
                  "."
              ],
              "exclude": [
                  "./docs",
                  "./node_modules",
                  "./public",
                  "./results",
                  "./scripts",
                  "./test"
              ],
              "includePattern": ".\\.png$"
          }
      },
}

It was working with pixi-jsdoc-template, but with pixi-webdoc-template it fails with
stacktrace

(node:26703) UnhandledPromiseRejectionWarning: Error: Cannot find module 'jsdoc/src/filter'
Require stack:
- /project/node_modules/@pixi/webdoc-template/publish.js
- /project/node_modules/@webdoc/cli/lib/index.js
- /project/node_modules/@webdoc/cli/cli.js
    at Function.Module._resolveFilename (internal/modules/cjs/loader.js:957:15)
    at Function.Module._load (internal/modules/cjs/loader.js:840:27)
    at Module.require (internal/modules/cjs/loader.js:1019:19)
    at require (internal/modules/cjs/helpers.js:77:18)

I tried to debug and don't understand how it works jsdoc doesn't have public src folder

Can't be installed with Yarn

When I try to install this package with yarn, I get the following error:

nigel$ mkdir new_project
nigel$ cd new_project/
nigel$ yarn add @pixi/webdoc-template
yarn add v1.22.10
info No lockfile found.
[1/4] ๐Ÿ”  Resolving packages...
[2/4] ๐Ÿšš  Fetching packages...
warning @pixi/[email protected]: The engine "pnpm" appears to be invalid.
error @pixi/[email protected]: The engine "yarn" is incompatible with this module. Expected version "please-use-npm". Got "1.22.10"
error Found incompatible module.
info Visit https://yarnpkg.com/en/docs/cli/add for documentation about this command.

The package.json specifies please-use-npm in the engines section, but I believe this is only for developers of this package (to avoid developers of this package using both yarn and npm and generating conflicting package-lock.json vs yarn.lock). It should not be enforced for consumers installing this package in their projects, and should be possible to install webdoc-template via yarn

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.