Skip to content

fratorgano/Trenode.js

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

84 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

trenodeIcon

Trenode.js

Trenode.js is a project I'm working on to give me and my friend an easy way to check italian trains schedule and real time train tracking through Trenitalia API. This is my first Javascript/Node project so I'm sure there is a lot of spaghetti code.
Feel free to contribute!
Here is the website: Trenode.js

Current features

  • Search train solutions between two destinations at a certain date and time
  • Choosing a solution allows to check the trains status, including trains numbers, platforms and delays
  • Autocompleting date, time(to current ones) and station names in the form
  • Fully responsive layout
  • Mobile friendly
  • Automatic dark mode
  • Page to check timetable of stations for both arrivals and departures
  • Push notifications for timetable updates

What's new in version 2.2

  • Officially a web app! Now you can add it to your home screen and use it as a native app
  • Added push notifications to the timetable page to get notified about train updates

What's new in version 2.1

  • Fixed bug when Trenitalia provided solutions with some null values
  • Added new page to check timetable of stations for both arrivals and departures

What's new in version 2.0

  • Solutions with more than a train now render properly
  • Status train's page now automatically refreshes every minute
  • Almost completely code rewrite with promises (await and async too)
  • Updated layout of all the pages, now fully HTML5 compliant
  • Added dark mode
  • Removed deprecated package for api requests. Now using Axios
  • Cleaned up the code a bit
  • Removed useless files from the repo (node_modules)

Known issues

  • Viaggiatreno APIs are not always reliable so train status might show the wrong train when checking the real time tracking (especially if checking a train that has not departed yet)

Try it

If you want to try it on your local machine, you just need to run some simple commands

  1. Either download the repo or clone it (git clone https://github.com/fratorgano/Trenode.js)
  2. Go to the folder you cloned it to
  3. Run the following commands
    1. npm install (Which install all the modules needed, it shouldn't fail but if it does, just run it again)
    2. npm start (Starts the server on localhost:8080)

Dependencies/Modules Used

Server-side

Client-side

License

Trenode.js is released under the MIT License.