move event handlers to component object
rewrite edit page to use state instead of props
add validation lib
Fix line endings in lib
submit site only if it is valid
Normalize all the line endings