Setup
Scaffold the Todo app project and start the development server.
Clone & Initialize
Clone Thunder and initialize a fresh project:
git clone https://github.com/Huruf-Tech/thunder.git my-todo-app
cd my-todo-app
deno task initdeno task init is only for a freshly cloned project. Running it again reinitializes the git repository and can cause irreversible loss of history.
Configure the Database
Create a .env file pointing at your MongoDB instance:
echo "DATABASE_URL=mongodb://localhost:27017/todo-app" > .env(Optional) Add thunder-core
If you want authentication and per-user todos later on, install the core plugin now:
deno task add:plugin -n Huruf-Tech/thunder-coreThis example works without it, but thunder-core is what you'd reach for to scope todos to a logged-in user.
Run the Dev Server
deno task devYour server is now live at http://localhost:8000. Next, we'll define the data model.