friends-best/server/index.ts
Louis Hollingworth 2e98cb39f4
Add tailwindcss, add first page
Signed-off-by: Louis Hollingworth <louis@hollingworth.ch>
2022-11-13 20:53:51 +00:00

9 lines
320 B
TypeScript

import mongoose from 'mongoose';
const runtimeConfig = useRuntimeConfig();
import {Nitro} from 'nitropack';
export default async (_nitroApp: Nitro) => {
mongoose.connect(runtimeConfig.mongoUri)
.then(() => console.log('connected to db'))
.catch(err => console.log('error connecting to db', err));
};