TomVeeDee / PageRankSimulator

Javascript PageRank simulator for Junior College of KU Leuven

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

pageranksimulator

Overview of the files/pages in src

  • package.json used by package manager yarn or npm
  • presets.js this file contains the presets that can be loaded using the presets button
  • main.js main js file, contains Vue configuration setup
  • App.vue is the starting point for the whole app
  • plugins/ contains plugins used
  • pagerank/ simple iterative implementation of the pagerank algorithm. All files here contains pure logic and have nothing to do with the visual representation.
    • /test/ contains tests for the pagerank algorithm implementation
    • /Node.js node representing a website, used in the algoritm
    • /PageRankSimulator.js the algorithm itself
  • components/ Contains the components used in the app, this is only visual representation, all logic is in pagerank/ folder.
    • /DrawGraph.js Contains the code to draw the graph on an canvas object
    • /Graph.vue Vue component, this component contains a canvas on wich DrawGraph draws
    • /canvascomponents/
      • /ConnectorC.js A connector component, is visual representation of a connection
      • /NodeC.js A node component, visual representation of a node
      • /pixi.js Used to import only the parts of the PixiJS library needed an thus allowing webpack to lower the size, normally there is no need to edit this.
  • assets/ images etc.

Layout overview

How to run and build the app

How to generate the files for the webserver

  1. Clone this project
  2. install Yarn package manager
  3. run yarn install to install all necessary libraries - this might take several minutes
  4. run yarn build to build the app - this make take several minutes
  5. output files are in the dist folder

Run locally

Don't use this in production

  1. Clone this project
  2. install Yarn package manager
  3. run yarn install to install all necessary libraries - this might take several minutes
  4. run yarn serve to build the app - this make take several minutes
  5. now go to the link shown in the console, if you edit a file, the app will automatically be updated

How to test the app

First follow steps 1-3 from previous paragraph, than use yarn test.

About

Javascript PageRank simulator for Junior College of KU Leuven


Languages

Language:JavaScript 66.8%Language:Vue 33.2%