GithubHelp home page GithubHelp logo

0haodha / traintracker Goto Github PK

View Code? Open in Web Editor NEW
1.0 1.0 0.0 11.96 MB

CT216 Project - Irish Rail Train Tracker

Home Page: https://irishrailtracker.web.app/

JavaScript 28.14% HTML 0.34% Vue 71.52%

traintracker's People

Contributors

0haodha avatar conorjmcnamara avatar j-lennox10 avatar jlennox1 avatar

Stargazers

 avatar

Watchers

 avatar  avatar  avatar

traintracker's Issues

Remove `dist` directory from version control

To my knowledge, the dist directory contains only build artefacts and nothing else, so there is no reason why it should be in the version control. Seeing as we never actually distribute the contents of this build directory, as it is only used for a local build during development/testing and the actual live site is almost always deployed to by a build from Github Actions, there is no reason (to my knowledge) why this directory should be included in the repository.

"Error fetching live train data" Toast

A "toast" is displayed when there is no data in the response of the getLiveTrainData function, which is undesirable for two reasons:

  1. Most of the time when this occurs, it is not an error - there is simply just no train data, e.g. late at night. At the time of writing this, it is just after 02:00 on a Tuesday morning, and therefore there are no running trains, and no train data is to be expected.
  2. Even when this an error, it's not good to display this to the user as there is nothing they can do about it and it will likely just confuse them. Instead, if no data is shown, they will likely just refresh the page, without any unnecessary software gore or confusion, and this will likely solve the issue.
    image

Proposed solution: Replace all instances of this throwing an error, which is subsequently caught by the toast system, with simple console.warn() statements. This maintains the useful output for developers while a) not falsely asserting that there is an error when there likely is none, and b) without upsetting the user.

Effected files:
image

  • src/pages/InsightsPage.vue
  • src/pages/MapPage.vue
  • And in a similar, but not exactly the same issue: functions/index.js

No OpenStreetMap Attribution

The OpenLayers map tiles used are sourced from OpenStreetMap, which has clear attribution rules. Nowhere on the website is OSM attributed for their tiles.
These rules can be found here: https://wiki.osmfoundation.org/wiki/Licence/Attribution_Guidelines.

Potential Solutions:

  • This is likely built-in to vue3-openlayers, so this should be used if possible.
  • Alternatively, a custom attribution message can easily be created from scratch in accordance to OSM's guidelines.

Remove irrelevant files from repo

The repo contains many files that do not need to be here such as the contents of the .idea and .vscode directories.

These should be added to the gitignore and removed from the cache

Better Project Documentation

There is little information on this project for someone who is seeing it for the first time with no context. There should be much more documenation for this project, including, but not necessarily limited to:

  • An "About" page on the website, detailing the purpose of the project, the motivations behind it, the technologies used, & the developers.
  • Far more information about the project in the README, rather than just information on how to set up the project locally.
  • The PDF report submitted for this project should be publicly published.

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.