mirror of
https://github.com/mmahdium/portfolio.git
synced 2025-12-20 09:23:54 +01:00
Removed unused code
This commit is contained in:
@@ -1 +0,0 @@
|
|||||||
NUXT_PUBLIC_LOAD_PLAUSIBLE="no"
|
|
||||||
|
|||||||
@@ -133,8 +133,7 @@ Compatible with any static hosting service:
|
|||||||
**Output Directory**: `.output/public`
|
**Output Directory**: `.output/public`
|
||||||
|
|
||||||
### Environment Variables
|
### Environment Variables
|
||||||
- `NUXT_PUBLIC_LOAD_PLAUSIBLE` - Enable/disable Plausible analytics (optional)
|
- `NUXT_PUBLIC_SITE_URL` - Site URL for sitemap and RSS (default: https://mahdium.ir)
|
||||||
- `NUXT_PUBLIC_SITE_URL` - Site URL for sitemap and RSS (default: https://aliarghyani.vercel.app)
|
|
||||||
|
|
||||||
## 🧪 Testing the Structure
|
## 🧪 Testing the Structure
|
||||||
|
|
||||||
|
|||||||
@@ -1,61 +0,0 @@
|
|||||||
<template>
|
|
||||||
<div class="bg-blue-950 backdrop-blur-md hover:cursor-pointer" v-show="open">
|
|
||||||
<div
|
|
||||||
class="plausible-event-name=VueSchoolBanner+click flex h-16 shrink-0 items-center justify-between px-4 text-white"
|
|
||||||
@click="navigate"
|
|
||||||
>
|
|
||||||
<div></div>
|
|
||||||
<div class="hidden lg:block">
|
|
||||||
<img src="/img/vueschool/vueschool.svg" alt="VueSchool Logo" class="h-6" />
|
|
||||||
</div>
|
|
||||||
<div
|
|
||||||
class="hidden bg-gradient-to-r from-amber-400 to-pink-500 bg-clip-text text-lg font-semibold tracking-wide text-transparent sm:inline-block"
|
|
||||||
>
|
|
||||||
New Vue Masterclass
|
|
||||||
</div>
|
|
||||||
<div class="hidden lg:flex lg:gap-x-2">
|
|
||||||
<img src="/img/vueschool/vue-with-hat.svg" alt="VueJS Logo" class="h-6" />
|
|
||||||
<img src="/img/vueschool/pinia.svg" alt="Pinia Logo" class="h-6" />
|
|
||||||
<img src="/img/vueschool/vite.svg" alt="Vite Logo" class="h-6" />
|
|
||||||
<img src="/img/vueschool/vitest.svg" alt="Vitest Logo" class="h-6" />
|
|
||||||
</div>
|
|
||||||
<div class="text-center leading-5">
|
|
||||||
<span
|
|
||||||
class="inline-block bg-gradient-to-r from-emerald-300 to-sky-300 bg-clip-text font-semibold tracking-wide text-transparent"
|
|
||||||
>
|
|
||||||
Vue.js Masterclass 2024 Edition
|
|
||||||
</span>
|
|
||||||
<span class="ml-2 hidden font-semibold sm:inline">LAUNCHED</span>
|
|
||||||
<br />
|
|
||||||
<span class="text-sm text-gray-300 sm:text-base">
|
|
||||||
Code a real world app using the latest Vue.js tech
|
|
||||||
</span>
|
|
||||||
</div>
|
|
||||||
<UButton
|
|
||||||
class="plausible-event-name=VueSchoolBanner+click hidden px-4 font-bold md:inline-flex rounded-full"
|
|
||||||
label="Buy Now"
|
|
||||||
icon="i-tabler-caret-right-filled"
|
|
||||||
variant="solid"
|
|
||||||
trailing
|
|
||||||
@click="navigate"
|
|
||||||
/>
|
|
||||||
<UIcon
|
|
||||||
name="i-ph-x"
|
|
||||||
class="size-8 p-2 hover:opacity-80"
|
|
||||||
@click.stop="open = false"
|
|
||||||
/>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
</template>
|
|
||||||
|
|
||||||
<script setup lang="ts">
|
|
||||||
const open = ref(true)
|
|
||||||
const affiliateId = "UILIBPIC"
|
|
||||||
const fullUrl = computed(
|
|
||||||
() => `https://vueschool.io/the-vuejs-3-master-class?friend=${affiliateId}`
|
|
||||||
)
|
|
||||||
|
|
||||||
const navigate = () => {
|
|
||||||
window.open(fullUrl.value, "_blank")
|
|
||||||
}
|
|
||||||
</script>
|
|
||||||
@@ -51,7 +51,7 @@ const nextPost = computed(() => {
|
|||||||
})
|
})
|
||||||
|
|
||||||
// SEO meta tags
|
// SEO meta tags
|
||||||
const siteUrl = 'https://aliarghyani.vercel.app' // TODO: Move to runtime config
|
const siteUrl = 'https://mahdium.ir' // TODO: Move to runtime config
|
||||||
|
|
||||||
// Custom meta tags
|
// Custom meta tags
|
||||||
if (post.value) {
|
if (post.value) {
|
||||||
|
|||||||
@@ -1,6 +0,0 @@
|
|||||||
export default defineNuxtPlugin(() => {
|
|
||||||
const script = document.createElement("script")
|
|
||||||
script.src = "https://media.bitterbrains.com/main.js?from=UILIB&type=top"
|
|
||||||
script.async = true
|
|
||||||
document.head.appendChild(script)
|
|
||||||
})
|
|
||||||
172
nuxt.config.ts
172
nuxt.config.ts
@@ -1,90 +1,91 @@
|
|||||||
// https://nuxt.com/docs/api/configuration/nuxt-config
|
// https://nuxt.com/docs/api/configuration/nuxt-config
|
||||||
export default defineNuxtConfig({
|
export default defineNuxtConfig({
|
||||||
srcDir: 'app',
|
srcDir: "app",
|
||||||
|
|
||||||
// Enable View Transitions API for smooth page transitions
|
// Enable View Transitions API for smooth page transitions
|
||||||
experimental: {
|
experimental: {
|
||||||
viewTransition: true
|
viewTransition: true,
|
||||||
},
|
},
|
||||||
|
|
||||||
// Configure page and layout transitions
|
// Configure page and layout transitions
|
||||||
app: {
|
app: {
|
||||||
baseURL: '/',
|
baseURL: "/",
|
||||||
buildAssetsDir: '/_nuxt/',
|
buildAssetsDir: "/_nuxt/",
|
||||||
cdnURL: '/',
|
cdnURL: "/",
|
||||||
pageTransition: {
|
pageTransition: {
|
||||||
name: 'page',
|
name: "page",
|
||||||
mode: 'out-in'
|
mode: "out-in",
|
||||||
},
|
},
|
||||||
layoutTransition: {
|
layoutTransition: {
|
||||||
name: 'layout',
|
name: "layout",
|
||||||
mode: 'out-in'
|
mode: "out-in",
|
||||||
}
|
},
|
||||||
},
|
},
|
||||||
|
|
||||||
modules: [
|
modules: [
|
||||||
'@nuxt/content',
|
"@nuxt/content",
|
||||||
'@nuxt/fonts',
|
"@nuxt/fonts",
|
||||||
'@nuxt/ui',
|
"@nuxt/ui",
|
||||||
'@nuxtjs/i18n',
|
"@nuxtjs/i18n",
|
||||||
'@nuxtjs/color-mode',
|
"@nuxtjs/color-mode",
|
||||||
'@nuxt/image',
|
"@nuxt/image",
|
||||||
'@nuxtjs/sitemap'
|
"@nuxtjs/sitemap",
|
||||||
],
|
|
||||||
css: [
|
|
||||||
'~/assets/css/main.css'
|
|
||||||
],
|
],
|
||||||
|
css: ["~/assets/css/main.css"],
|
||||||
postcss: {
|
postcss: {
|
||||||
plugins: {
|
plugins: {
|
||||||
'@csstools/postcss-oklab-function': { preserve: false },
|
"@csstools/postcss-oklab-function": { preserve: false },
|
||||||
'@csstools/postcss-relative-color-syntax': { preserve: false },
|
"@csstools/postcss-relative-color-syntax": { preserve: false },
|
||||||
'@csstools/postcss-color-mix-function': { preserve: false },
|
"@csstools/postcss-color-mix-function": { preserve: false },
|
||||||
'postcss-preset-env': {
|
"postcss-preset-env": {
|
||||||
stage: 0,
|
stage: 0,
|
||||||
features: {
|
features: {
|
||||||
'nesting-rules': true
|
"nesting-rules": true,
|
||||||
}
|
},
|
||||||
},
|
},
|
||||||
autoprefixer: {}
|
autoprefixer: {},
|
||||||
}
|
},
|
||||||
},
|
},
|
||||||
vite: {
|
vite: {
|
||||||
css: {
|
css: {
|
||||||
lightningcss: {
|
lightningcss: {
|
||||||
targets: {
|
targets: {
|
||||||
safari: 15
|
safari: 15,
|
||||||
}
|
},
|
||||||
}
|
},
|
||||||
}
|
},
|
||||||
},
|
},
|
||||||
fonts: {
|
fonts: {
|
||||||
defaults: {
|
defaults: {
|
||||||
preload: true,
|
preload: true,
|
||||||
weights: [300, 400, 500, 600, 700],
|
weights: [300, 400, 500, 600, 700],
|
||||||
styles: ['normal'],
|
styles: ["normal"],
|
||||||
subsets: ['latin'],
|
subsets: ["latin"],
|
||||||
fallbacks: {
|
fallbacks: {
|
||||||
'sans-serif': ['system-ui', 'Segoe UI', 'sans-serif'],
|
"sans-serif": ["system-ui", "Segoe UI", "sans-serif"],
|
||||||
serif: ['Georgia', 'Times New Roman', 'serif']
|
serif: ["Georgia", "Times New Roman", "serif"],
|
||||||
}
|
},
|
||||||
},
|
},
|
||||||
families: [
|
families: [
|
||||||
{ name: 'Fraunces', provider: 'google', weights: [600, 700] },
|
{ name: "Fraunces", provider: "google", weights: [600, 700] },
|
||||||
{ name: 'Inter', provider: 'google', weights: [400, 500, 600, 700] },
|
{ name: "Inter", provider: "google", weights: [400, 500, 600, 700] },
|
||||||
{ name: 'Outfit', provider: 'google', weights: [300, 400, 500, 600, 700] }
|
{
|
||||||
]
|
name: "Outfit",
|
||||||
|
provider: "google",
|
||||||
|
weights: [300, 400, 500, 600, 700],
|
||||||
|
},
|
||||||
|
],
|
||||||
},
|
},
|
||||||
|
|
||||||
runtimeConfig: {
|
runtimeConfig: {
|
||||||
public: {
|
public: {
|
||||||
loadPlausible: "", // overrided by env,
|
siteUrl: "https://mahdium.ir", // Used for sitemap and RSS generation
|
||||||
siteUrl: 'https://aliarghyani.vercel.app' // Used for sitemap and RSS generation
|
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
|
|
||||||
// Site configuration for sitemap
|
// Site configuration for sitemap
|
||||||
site: {
|
site: {
|
||||||
url: 'https://aliarghyani.vercel.app'
|
url: "https://mahdium.ir",
|
||||||
} as any,
|
} as any,
|
||||||
|
|
||||||
// Sitemap configuration
|
// Sitemap configuration
|
||||||
@@ -92,9 +93,9 @@ export default defineNuxtConfig({
|
|||||||
gzip: true,
|
gzip: true,
|
||||||
exclude: [],
|
exclude: [],
|
||||||
defaults: {
|
defaults: {
|
||||||
changefreq: 'monthly',
|
changefreq: "monthly",
|
||||||
priority: 0.8
|
priority: 0.8,
|
||||||
}
|
},
|
||||||
} as any,
|
} as any,
|
||||||
|
|
||||||
image: {
|
image: {
|
||||||
@@ -106,9 +107,9 @@ export default defineNuxtConfig({
|
|||||||
md: 768,
|
md: 768,
|
||||||
lg: 1024,
|
lg: 1024,
|
||||||
xl: 1280,
|
xl: 1280,
|
||||||
'2xl': 1536
|
"2xl": 1536,
|
||||||
},
|
},
|
||||||
formats: ['webp', 'jpg']
|
formats: ["webp", "jpg"],
|
||||||
},
|
},
|
||||||
typescript: {
|
typescript: {
|
||||||
shim: false,
|
shim: false,
|
||||||
@@ -131,75 +132,82 @@ export default defineNuxtConfig({
|
|||||||
storageKey: "nuxt-color-mode",
|
storageKey: "nuxt-color-mode",
|
||||||
},
|
},
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
// Nuxt Content configuration
|
// Nuxt Content configuration
|
||||||
content: {
|
content: {
|
||||||
// Disable experimental features that require native dependencies
|
// Disable experimental features that require native dependencies
|
||||||
experimental: {
|
experimental: {
|
||||||
clientDB: false,
|
clientDB: false,
|
||||||
cacheContents: false
|
cacheContents: false,
|
||||||
},
|
},
|
||||||
markdown: {
|
markdown: {
|
||||||
mdc: true,
|
mdc: true,
|
||||||
toc: {
|
toc: {
|
||||||
depth: 3,
|
depth: 3,
|
||||||
searchDepth: 3
|
searchDepth: 3,
|
||||||
}
|
},
|
||||||
},
|
},
|
||||||
documentDriven: false,
|
documentDriven: false,
|
||||||
respectPathCase: true
|
respectPathCase: true,
|
||||||
},
|
},
|
||||||
|
|
||||||
i18n: {
|
i18n: {
|
||||||
defaultLocale: 'en',
|
defaultLocale: "en",
|
||||||
strategy: 'prefix_except_default',
|
strategy: "prefix_except_default",
|
||||||
locales: [
|
locales: [
|
||||||
{ code: 'en', language: 'en-US', name: 'English', dir: 'ltr', file: 'en.json' },
|
{
|
||||||
{ code: 'fa', language: 'fa-IR', name: 'فارسی', dir: 'rtl', file: 'fa.json' },
|
code: "en",
|
||||||
|
language: "en-US",
|
||||||
|
name: "English",
|
||||||
|
dir: "ltr",
|
||||||
|
file: "en.json",
|
||||||
|
},
|
||||||
|
{
|
||||||
|
code: "fa",
|
||||||
|
language: "fa-IR",
|
||||||
|
name: "فارسی",
|
||||||
|
dir: "rtl",
|
||||||
|
file: "fa.json",
|
||||||
|
},
|
||||||
],
|
],
|
||||||
langDir: 'locales',
|
langDir: "locales",
|
||||||
detectBrowserLanguage: {
|
detectBrowserLanguage: {
|
||||||
useCookie: true,
|
useCookie: true,
|
||||||
cookieKey: 'i18n_redirected',
|
cookieKey: "i18n_redirected",
|
||||||
alwaysRedirect: false,
|
alwaysRedirect: false,
|
||||||
redirectOn: 'root'
|
redirectOn: "root",
|
||||||
},
|
},
|
||||||
// Keep runtime vue-i18n options (legacy, warnings)
|
// Keep runtime vue-i18n options (legacy, warnings)
|
||||||
vueI18n: '~/i18n.config.ts'
|
vueI18n: "~/i18n.config.ts",
|
||||||
},
|
},
|
||||||
|
|
||||||
// Prerender blog routes
|
// Prerender blog routes
|
||||||
nitro: {
|
nitro: {
|
||||||
prerender: {
|
prerender: {
|
||||||
crawlLinks: true,
|
crawlLinks: true,
|
||||||
routes: ['/', '/blog', '/fa/blog'],
|
routes: ["/", "/blog", "/fa/blog"],
|
||||||
failOnError: false,
|
failOnError: false,
|
||||||
ignore: ['/_vercel/image']
|
ignore: ["/_vercel/image"],
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
// Route rules for caching and optimization
|
// Route rules for caching and optimization
|
||||||
routeRules: {
|
routeRules: {
|
||||||
// Blog routes caching
|
// Blog routes caching
|
||||||
'/blog': { swr: 3600 },
|
"/blog": { swr: 3600 },
|
||||||
'/fa/blog': { swr: 3600 },
|
"/fa/blog": { swr: 3600 },
|
||||||
'/blog/**': { swr: 3600 },
|
"/blog/**": { swr: 3600 },
|
||||||
'/fa/blog/**': { swr: 3600 }
|
"/fa/blog/**": { swr: 3600 },
|
||||||
},
|
},
|
||||||
|
|
||||||
devtools: { enabled: false },
|
// devtools: { enabled: false },
|
||||||
compatibilityDate: "2024-07-10",
|
compatibilityDate: "2024-07-10",
|
||||||
|
|
||||||
components: {
|
components: {
|
||||||
dirs: [
|
dirs: [
|
||||||
{
|
{
|
||||||
path: '~/components',
|
path: "~/components",
|
||||||
pathPrefix: false
|
pathPrefix: false,
|
||||||
}
|
},
|
||||||
]
|
],
|
||||||
}
|
},
|
||||||
})
|
});
|
||||||
|
|||||||
20
package.json
20
package.json
@@ -13,36 +13,36 @@
|
|||||||
"format:write": "prettier --write ."
|
"format:write": "prettier --write ."
|
||||||
},
|
},
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"@nuxt/content": "^3.8.0",
|
"@nuxt/content": "^3.8.2",
|
||||||
"@nuxt/fonts": "^0.11.4",
|
"@nuxt/fonts": "^0.11.4",
|
||||||
"@nuxt/image": "^1.11.0",
|
"@nuxt/image": "^1.11.0",
|
||||||
"@nuxt/ui": "^4.0.1",
|
"@nuxt/ui": "^4.2.1",
|
||||||
"@nuxtjs/color-mode": "3.5.2",
|
"@nuxtjs/color-mode": "3.5.2",
|
||||||
"@nuxtjs/i18n": "10.1.1",
|
"@nuxtjs/i18n": "10.1.1",
|
||||||
"@vueuse/core": "13.9.0",
|
"@vueuse/core": "13.9.0",
|
||||||
"better-sqlite3": "^12.4.1",
|
"better-sqlite3": "^12.5.0",
|
||||||
"embla-carousel": "8.6.0",
|
"embla-carousel": "8.6.0",
|
||||||
"nuxt": "^4.1.3"
|
"nuxt": "^4.2.1"
|
||||||
},
|
},
|
||||||
"devDependencies": {
|
"devDependencies": {
|
||||||
"@csstools/postcss-color-mix-function": "^3.0.12",
|
"@csstools/postcss-color-mix-function": "^3.0.12",
|
||||||
"@csstools/postcss-oklab-function": "^4.0.12",
|
"@csstools/postcss-oklab-function": "^4.0.12",
|
||||||
"@csstools/postcss-relative-color-syntax": "^3.0.12",
|
"@csstools/postcss-relative-color-syntax": "^3.0.12",
|
||||||
"@iconify-json/logos": "^1.2.9",
|
"@iconify-json/logos": "^1.2.10",
|
||||||
"@iconify-json/material-symbols": "^1.2.42",
|
"@iconify-json/material-symbols": "^1.2.48",
|
||||||
"@iconify-json/mdi": "^1.2.3",
|
"@iconify-json/mdi": "^1.2.3",
|
||||||
"@iconify-json/ph": "^1.2.2",
|
"@iconify-json/ph": "^1.2.2",
|
||||||
"@iconify-json/twemoji": "^1.2.4",
|
"@iconify-json/twemoji": "^1.2.4",
|
||||||
"@iconify-json/vscode-icons": "^1.2.32",
|
"@iconify-json/vscode-icons": "^1.2.37",
|
||||||
"@nuxtjs/sitemap": "^7.4.7",
|
"@nuxtjs/sitemap": "^7.4.7",
|
||||||
"@tailwindcss/vite": "^4.1.14",
|
"@tailwindcss/vite": "^4.1.17",
|
||||||
"@types/node": "22.18.11",
|
"@types/node": "22.18.11",
|
||||||
"autoprefixer": "^10.4.21",
|
"autoprefixer": "^10.4.22",
|
||||||
"postcss": "^8.5.6",
|
"postcss": "^8.5.6",
|
||||||
"postcss-preset-env": "^10.4.0",
|
"postcss-preset-env": "^10.4.0",
|
||||||
"prettier": "3.6.2",
|
"prettier": "3.6.2",
|
||||||
"prettier-plugin-tailwindcss": "0.7.1",
|
"prettier-plugin-tailwindcss": "0.7.1",
|
||||||
"tailwindcss": "^4.1.14",
|
"tailwindcss": "^4.1.17",
|
||||||
"typescript": "^5.9.3"
|
"typescript": "^5.9.3"
|
||||||
},
|
},
|
||||||
"overrides": {
|
"overrides": {
|
||||||
|
|||||||
2102
pnpm-lock.yaml
generated
2102
pnpm-lock.yaml
generated
File diff suppressed because it is too large
Load Diff
10
vercel.json
10
vercel.json
@@ -1,14 +1,4 @@
|
|||||||
{
|
{
|
||||||
"rewrites": [
|
|
||||||
{
|
|
||||||
"source": "/stats/js/script.js",
|
|
||||||
"destination": "https://plausible.io/js/script.tagged-events.js"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"source": "/stats/api/event",
|
|
||||||
"destination": "https://plausible.io/api/event"
|
|
||||||
}
|
|
||||||
],
|
|
||||||
"headers": [
|
"headers": [
|
||||||
{
|
{
|
||||||
"source": "/_nuxt/(.*)",
|
"source": "/_nuxt/(.*)",
|
||||||
|
|||||||
Reference in New Issue
Block a user