Vanilla JS implementation
Sync with localhost