Use Python to map a website's internal links. And then apply D3 to visualize those connections as a network graph.
- Git
- Python (When installing on Windows, make sure you check the "Add python 3.xx to PATH" box.)
- Install the above programs.
- Open a shell window (For Windows open PowerShell, for MacOS open Terminal & for Linux open your distro's terminal emulator).
- Clone this repository using
git
by running the following command;git clone https://github.com/devbret/website-internal-links
. - Navigate to the repo's directory by running;
cd website-internal-links
. - Install the needed dependencies for running the script by running;
pip install -r requirements.txt
. - Edit the app.py file on line 49, to include the website that you would like to visualize.
- Run the script with the command
python3 app.py
. - To view the website's connections in the index.html file you will need to run a local web server. To do this run
python3 -m http.server
.