Azure CosmosDB - Next.js Starter

R
Renaudil y a 2 jours
0

Description

This is a Next.js project that uses @azure/cosmos JS SDK to connect to a Azure Cosmos DB database.

npx boilerapp azure-cosmosdb-nextjs-starter

Documentation

Azure Cosmos DB Starter – Todo App

A simple Todo App built on Next.js and Azure Cosmos DB, deployed on Vercel with the Vercel + Azure Cosmos DB integration.

Deployment Instructions

Pre requisites

Azure Cosmos DB account, database and container. Please make sure the Partition Key for container is '/id'.

Steps

  • Install dependencies from the root folder - npm install

  • Rename sample.env to .env and set appropriate variables.

    • COSMOSDB_CONNECTION_STRING : This is the connection string for Azure Cosmos DB.
    • COSMOSDB_DATABASE_NAME : This is the name of the database to store todos.
    • COSMOSDB_CONTAINER_NAME : This is the name of the container to store todos.

You can obtain the connection string by navigating to your Azure Cosmos DB account page's key blade, and select Primary connection string. Copy the value to use.

  • Start the project - npm run dev

Demo

https://cosmosdb-vercel-starter.vercel.app/

Vercel + Azure Cosmos DB Integration

https://vercel.com/integrations/azurecosmosdb5c:T4fd,# Azure Cosmos DB Starter – Todo App

A simple Todo App built on Next.js and Azure Cosmos DB, deployed on Vercel with the Vercel + Azure Cosmos DB integration.

Deployment Instructions

Pre requisites

Azure Cosmos DB account, database and container. Please make sure the Partition Key for container is '/id'.

Steps

  • Install dependencies from the root folder - npm install

  • Rename sample.env to .env and set appropriate variables.

    • COSMOSDB_CONNECTION_STRING : This is the connection string for Azure Cosmos DB.
    • COSMOSDB_DATABASE_NAME : This is the name of the database to store todos.
    • COSMOSDB_CONTAINER_NAME : This is the name of the container to store todos.

You can obtain the connection string by navigating to your Azure Cosmos DB account page's key blade, and select Primary connection string. Copy the value to use.

  • Start the project - npm run dev

Demo

https://cosmosdb-vercel-starter.vercel.app/

Vercel + Azure Cosmos DB Integration

https://vercel.com/integrations/azurecosmosdb

Prix

Gratuit

FREE

Commentaires (0)

FAQ

Questions Fréquemment Posées

Vous avez une question ? Nous avons les réponses. Si vous ne trouvez pas ce que vous cherchez, n'hésitez pas à nous contacter.

Boilerapp est une plateforme communautaire dédiée au partage de boilerplates, de starter kits et de modèles de projets pour développeurs. Notre objectif est simple : vous faire gagner du temps sur la configuration initiale (setup) pour que vous puissiez coder ce qui compte vraiment. Que vous cherchiez une simple base de code ou un projet SaaS complet, vous le trouverez ici.

Vous avez d'autres questions ?

Notre équipe est là pour vous aider. Contactez-nous et nous vous répondrons dès que possible.

Azure CosmosDB - Next.js Starter | BoilerApp