Skip to content

Instantly share code, notes, and snippets.

View ccthecode's full-sized avatar

ccthecode ccthecode

View GitHub Profile
import { defineConfig } from 'vite';
import react from '@vitejs/plugin-react';
// https://vitejs.dev/config/
export default defineConfig({
plugins: [react()],
optimizeDeps: {
exclude: ['lucide-react'],
},
build: {

Set the base image to Ubuntu must be first instruction - use docker search to find images

FROM ubuntu # <image>
FROM ubuntu:latest # - <image>:<tag>
FROM ubuntu:precise (LTS)

Set the maintainer info

@ccthecode
ccthecode / route.ts
Last active September 30, 2023 20:23
FIX to Error in [1:56:03]: Youtube Video: Build a SaaS AI Platform with Next.js 13, React, Tailwind, Prisma, Stripe | Full Tutorial 2023
import { auth } from "@clerk/nextjs";
import { NextResponse } from "next/server";
// Old way (v3)
// import { Configuration, OpenAIApi } from "openai"
// New way (v4)
import OpenAI from "openai"
const openai = new OpenAI({