From a079d06867f337fd2df84bb4323a5e462f8eda83 Mon Sep 17 00:00:00 2001 From: Josephat-S Date: Mon, 25 May 2026 12:00:59 +0200 Subject: [PATCH] Add a basic template for a Next.js portfolio --- .gitignore | 5 +++- .../portfolio/nextjs-monolith/.eslintrc.json | 4 +++ .../portfolio/nextjs-monolith/app/globals.css | 3 +++ .../portfolio/nextjs-monolith/app/layout.tsx | 19 ++++++++++++++ .../portfolio/nextjs-monolith/app/page.tsx | 26 +++++++++++++++++++ .../portfolio/nextjs-monolith/next.config.js | 4 +++ .../portfolio/nextjs-monolith/package.json | 21 +++++++++++++-- .../nextjs-monolith/postcss.config.js | 6 +++++ .../nextjs-monolith/tailwind.config.ts | 14 ++++++++++ .../portfolio/nextjs-monolith/tsconfig.json | 26 +++++++++++++++++++ 10 files changed, 125 insertions(+), 3 deletions(-) create mode 100644 templates/portfolio/nextjs-monolith/.eslintrc.json create mode 100644 templates/portfolio/nextjs-monolith/app/globals.css create mode 100644 templates/portfolio/nextjs-monolith/app/page.tsx create mode 100644 templates/portfolio/nextjs-monolith/next.config.js create mode 100644 templates/portfolio/nextjs-monolith/postcss.config.js create mode 100644 templates/portfolio/nextjs-monolith/tailwind.config.ts create mode 100644 templates/portfolio/nextjs-monolith/tsconfig.json diff --git a/.gitignore b/.gitignore index 1dcef2d..7ef8c73 100644 --- a/.gitignore +++ b/.gitignore @@ -1,2 +1,5 @@ node_modules -.env \ No newline at end of file +.env + +# editos files +.vscode \ No newline at end of file diff --git a/templates/portfolio/nextjs-monolith/.eslintrc.json b/templates/portfolio/nextjs-monolith/.eslintrc.json new file mode 100644 index 0000000..a2569c2 --- /dev/null +++ b/templates/portfolio/nextjs-monolith/.eslintrc.json @@ -0,0 +1,4 @@ +{ + "root": true, + "extends": "next/core-web-vitals" +} diff --git a/templates/portfolio/nextjs-monolith/app/globals.css b/templates/portfolio/nextjs-monolith/app/globals.css new file mode 100644 index 0000000..b5c61c9 --- /dev/null +++ b/templates/portfolio/nextjs-monolith/app/globals.css @@ -0,0 +1,3 @@ +@tailwind base; +@tailwind components; +@tailwind utilities; diff --git a/templates/portfolio/nextjs-monolith/app/layout.tsx b/templates/portfolio/nextjs-monolith/app/layout.tsx index e69de29..769d97d 100644 --- a/templates/portfolio/nextjs-monolith/app/layout.tsx +++ b/templates/portfolio/nextjs-monolith/app/layout.tsx @@ -0,0 +1,19 @@ +import type { Metadata } from 'next'; +import './globals.css'; + +export const metadata: Metadata = { + title: '{{projectName}} - Portfolio', + description: 'A {{variant}} portfolio built with Opusify CLI.', +}; + +export default function RootLayout({ + children, +}: { + children: React.ReactNode; +}) { + return ( + + {children} + + ); +} diff --git a/templates/portfolio/nextjs-monolith/app/page.tsx b/templates/portfolio/nextjs-monolith/app/page.tsx new file mode 100644 index 0000000..5368419 --- /dev/null +++ b/templates/portfolio/nextjs-monolith/app/page.tsx @@ -0,0 +1,26 @@ +export default function Home() { + return ( +
+

+ Welcome to {{projectName}} +

+

+ A {{variant}} portfolio, scaffolded by Opusify CLI. +

+
+ + View Projects + + + Contact Me + +
+
+ ); +} diff --git a/templates/portfolio/nextjs-monolith/next.config.js b/templates/portfolio/nextjs-monolith/next.config.js new file mode 100644 index 0000000..658404a --- /dev/null +++ b/templates/portfolio/nextjs-monolith/next.config.js @@ -0,0 +1,4 @@ +/** @type {import('next').NextConfig} */ +const nextConfig = {}; + +module.exports = nextConfig; diff --git a/templates/portfolio/nextjs-monolith/package.json b/templates/portfolio/nextjs-monolith/package.json index bb67fc5..5dfa145 100644 --- a/templates/portfolio/nextjs-monolith/package.json +++ b/templates/portfolio/nextjs-monolith/package.json @@ -1,10 +1,27 @@ { "name": "{{projectName}}", "version": "1.0.0", - "description": "A {{variant}} style {{template}} built with {{architecture}}.", + "private": true, + "scripts": { + "dev": "next dev", + "build": "next build", + "start": "next start", + "lint": "next lint" + }, "dependencies": { "next": "14.2.3", "react": "^18.3.1", "react-dom": "^18.3.1" + }, + "devDependencies": { + "@types/node": "^20.12.0", + "@types/react": "^18.3.0", + "@types/react-dom": "^18.3.0", + "autoprefixer": "^10.4.19", + "eslint": "^8.57.0", + "eslint-config-next": "14.2.3", + "postcss": "^8.4.38", + "tailwindcss": "^3.4.3", + "typescript": "^5.4.5" } -} \ No newline at end of file +} diff --git a/templates/portfolio/nextjs-monolith/postcss.config.js b/templates/portfolio/nextjs-monolith/postcss.config.js new file mode 100644 index 0000000..12a703d --- /dev/null +++ b/templates/portfolio/nextjs-monolith/postcss.config.js @@ -0,0 +1,6 @@ +module.exports = { + plugins: { + tailwindcss: {}, + autoprefixer: {}, + }, +}; diff --git a/templates/portfolio/nextjs-monolith/tailwind.config.ts b/templates/portfolio/nextjs-monolith/tailwind.config.ts new file mode 100644 index 0000000..cbcf2de --- /dev/null +++ b/templates/portfolio/nextjs-monolith/tailwind.config.ts @@ -0,0 +1,14 @@ +import type { Config } from 'tailwindcss'; + +const config: Config = { + content: [ + './app/**/*.{ts,tsx}', + './components/**/*.{ts,tsx}', + ], + theme: { + extend: {}, + }, + plugins: [], +}; + +export default config; diff --git a/templates/portfolio/nextjs-monolith/tsconfig.json b/templates/portfolio/nextjs-monolith/tsconfig.json new file mode 100644 index 0000000..e7ff90f --- /dev/null +++ b/templates/portfolio/nextjs-monolith/tsconfig.json @@ -0,0 +1,26 @@ +{ + "compilerOptions": { + "lib": ["dom", "dom.iterable", "esnext"], + "allowJs": true, + "skipLibCheck": true, + "strict": true, + "noEmit": true, + "esModuleInterop": true, + "module": "esnext", + "moduleResolution": "bundler", + "resolveJsonModule": true, + "isolatedModules": true, + "jsx": "preserve", + "incremental": true, + "plugins": [ + { + "name": "next" + } + ], + "paths": { + "@/*": ["./*"] + } + }, + "include": ["next-env.d.ts", "**/*.ts", "**/*.tsx", ".next/types/**/*.ts"], + "exclude": ["node_modules"] +}