https://github.com/mongodb-developer/remix
https://github.com/mongodb-developer/remix
Last synced: 9 months ago
JSON representation
- Host: GitHub
- URL: https://github.com/mongodb-developer/remix
- Owner: mongodb-developer
- Created: 2023-04-15T16:36:05.000Z (over 2 years ago)
- Default Branch: main
- Last Pushed: 2024-06-17T18:32:22.000Z (over 1 year ago)
- Last Synced: 2025-03-22T13:51:25.833Z (9 months ago)
- Language: TypeScript
- Size: 273 KB
- Stars: 12
- Watchers: 2
- Forks: 5
- Open Issues: 1
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# Remix stack for MongoDB
This simple stack includes everything you need to run Remix with MongoDB. It includes examples for basic document fetches, as well as a form to add new entries.
Find out more in the article in the [MongoDB Dev Center](https://mdb.link/remix).
## Requirements
Create a new Remix application using this template.
```
npx create-remix@latest --template mongodb-developer/remix
```
You will also need a MongoDB cluster ready to go with some sample data. The easiest way to get started is with an Atlas free cluster.
* Create your free Atlas cluster ([tutorial](https://www.mongodb.com/docs/atlas/tutorial/deploy-free-tier-cluster/?utm_campaign=devrel&utm_source=cross-post&utm_source=tools&utm_medium=readme&utm_content=remix-stack&utm_term=joel.lord))
* Load the sample dataset ([docs](https://www.mongodb.com/docs/atlas/sample-data/?utm_campaign=devrel&utm_source=cross-post&utm_source=tools&utm_medium=readme&utm_content=remix-stack&utm_term=joel.lord))
## Getting started
In the root folder of the project, create a `.env` file. In this file, you will need to add your connection string. Check out the [docs](https://www.mongodb.com/docs/guides/atlas/connection-string/?utm_campaign=devrel&utm_source=cross-post&utm_source=tools&utm_medium=readme&utm_content=remix-stack&utm_term=joel.lord) to learn how to get your connection string with Atlas.
```
CONNECTION_STRING=mongodb+srv://username:password@cluster0.abcdef.mongodb.net/myFirstDatabase
```
Run a first build, and then start the development environment.
```
npm run build
npm run dev
```
Open your browser on [http://localhost:3000](http://localhost:3000), and start exploring your new application.