got edit page to work! The problem was with the syntax of /edit:id in routes.js
updated edit/add buttons