Skip to content

Hexagon/pup-plugin-web-interface

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

14 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

pup web interface plugin

Development Documentation for Contributors

This is the development guide for contributors looking to help improve the pup web interface plugin. In order to ensure that your changes work correctly and in harmony with the existing codebase, please follow the steps outlined below.

Prerequisites

  • Have Deno installed on your machine.

  • Basic knowledge of how Bundlee works: Bundlee is a minimalistic bundler for JavaScript and TypeScript. It takes multiple JS/TS files, compiles them (if needed), and bundles them into a single JS file for use in a browser or Deno.

  • Understanding of how Oak works: Oak is a middleware framework for Deno's http server. It is somewhat similar to Express in Node.js and allows you to build efficient web applications and APIs.

Development Workflow

The pup web interface plugin uses Bundlee for bundling static assets, which includes files like 'static/web-interface.html', 'static/js/main.ts', and others. If you make any changes to these files, you will need to generate a new bundle and restart the pup instance.

Follow these steps to test your changes:

  1. Generate a new bundle

    Run deno task build from the root directory of the this project.

  2. Start an instance that uses the web-interface plugin

    Start the basic web interface example:

    pup run --cwd example

  3. Test the changes

    Browse to http://localhost:5000 to test your changes.

Contribution guidelines

Contributions to Pup are very welcome! Please read the contributing section of the manual, fork the repository, make your changes, and submit a pull request.