I'll help you create a portfolio website using Vue.js. Here's a complete setup with multiple sections and modern styling:
Project Setup
First, create a new Vue project:
bash
npm create vue@latest portfolio-website
cd portfolio-website
npm install
Main App Structure
src/App.vue
vue
<template>
<div id="app">
<Navbar />
<Hero />
<About />
<Skills />
<Projects />
<Contact />
<Footer />
</div>
</template>
<script>
import Navbar from './components/Navbar.vue'
import Hero from './components/Hero.vue'
import About from './components/About.vue'
import Skills from './components/Skills.vue'
import Projects from './components/Projects.vue'
import Contact from './components/Contact.vue'
import Footer from './components/Footer.vue'
export default {
name: 'App',
components: {
Navbar,
Hero,
About,
Skills,
Projects,
Contact,
Footer
}
}
</script>
<style>
* {
margin: 0;
padding: 0;
box-sizing: border-box;
}
body {
font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
line-height: 1.6;
color: #333;
}
#app {
min-height: 100vh;
}
</style>
Components
src/components/Navbar.vue
vue
<template>
<nav class="navbar">
<div class="nav-container">
<div class="nav-logo">
<h2>Your Name</h2>
</div>
<ul class="nav-menu" :class="{ active: isMenuOpen }">
<li><a href="#home" @click="closeMenu">Home</a></li>
<li><a href="#about" @click="closeMenu">About</a></li>
<li><a href="#skills" @click="closeMenu">Skills</a></li>
<li><a href="#projects" @click="closeMenu">Projects</a></li>
<li><a href="#contact" @click="closeMenu">Contact</a></li>
</ul>
<div class="nav-toggle" @click="toggleMenu">
<span></span>
<span></span>
<span></span>
</div>
</div>
</nav>
</template>
<script>
export default {
name: 'Navbar',
data() {
return {
isMenuOpen: false
}
},
methods: {
toggleMenu() {
this.isMenuOpen = !this.isMenuOpen
},
closeMenu() {
this.isMenuOpen = false
}
}
}
</script>
<style scoped>
.navbar {
position: fixed;
top: 0;
width: 100%;
background: rgba(255, 255, 255, 0.95);
backdrop-filter: blur(10px);
z-index: 1000;
padding: 1rem 0;
box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
}
.nav-container {
max-width: 1200px;
margin: 0 auto;
padding: 0 2rem;
display: flex;
justify-content: space-between;
align-items: center;
}
.nav-logo h2 {
color: #2c3e50;
font-weight: 700;
}
.nav-menu {
display: flex;
list-style: none;
gap: 2rem;
}
.nav-menu a {
text-decoration: none;
color: #2c3e50;
font-weight: 500;
transition: color 0.3s ease;
}
.nav-menu a:hover {
color: #3498db;
}
.nav-toggle {
display: none;
flex-direction: column;
cursor: pointer;
}
.nav-toggle span {
width: 25px;
height: 3px;
background: #2c3e50;
margin: 3px 0;
transition: 0.3s;
}
@media (max-width: 768px) {
.nav-menu {
position: fixed;
left: -100%;
top: 70px;
flex-direction: column;
background: white;
width: 100%;
text-align: center;
transition: 0.3s;
box-shadow: 0 10px 27px rgba(0, 0, 0, 0.05);
padding: 2rem 0;
}
.nav-menu.active {
left: 0;
}
.nav-toggle {
display: flex;
}
}
</style>
src/components/Hero.vue
vue
<template>
<section id="home" class="hero">
<div class="hero-container">
<div class="hero-content">
<h1 class="hero-title">
Hi, I'm <span class="highlight">Your Name</span>
</h1>
<p class="hero-subtitle">Full Stack Developer & UI/UX Designer</p>
<p class="hero-description">
I create beautiful, responsive web applications with modern technologies
and user-centered design principles.
</p>
<div class="hero-buttons">
<a href="#projects" class="btn btn-primary">View My Work</a>
<a href="#contact" class="btn btn-secondary">Get In Touch</a>
</div>
</div>
<div class="hero-image">
<div class="image-placeholder">
<!-- Replace with your actual image -->
<img src="/api/placeholder/400/400" alt="Profile" />
</div>
</div>
</div>
</section>
</template>
<script>
export default {
name: 'Hero'
}
</script>
<style scoped>
.hero {
min-height: 100vh;
display: flex;
align-items: center;
background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
color: white;
padding-top: 80px;
}
.hero-container {
max-width: 1200px;
margin: 0 auto;
padding: 0 2rem;
display: grid;
grid-template-columns: 1fr 1fr;
gap: 4rem;
align-items: center;
}
.hero-title {
font-size: 3.5rem;
font-weight: 700;
margin-bottom: 1rem;
line-height: 1.2;
}
.highlight {
color: #ffd700;
}
.hero-subtitle {
font-size: 1.5rem;
margin-bottom: 1rem;
opacity: 0.9;
}
.hero-description {
font-size: 1.1rem;
margin-bottom: 2rem;
opacity: 0.8;
line-height: 1.6;
}
.hero-buttons {
display: flex;
gap: 1rem;
flex-wrap: wrap;
}
.btn {
padding: 12px 30px;
text-decoration: none;
border-radius: 50px;
font-weight: 600;
transition: all 0.3s ease;
display: inline-block;
}
.btn-primary {
background: #ffd700;
color: #2c3e50;
}
.btn-primary:hover {
background: #ffed4e;
transform: translateY(-2px);
}
.btn-secondary {
border: 2px solid white;
color: white;
}
.btn-secondary:hover {
background: white;
color: #667eea;
}
.image-placeholder {
width: 400px;
height: 400px;
border-radius: 50%;
overflow: hidden;
margin: 0 auto;
box-shadow: 0 20px 40px rgba(0, 0, 0, 0.2);
}
.image-placeholder img {
width: 100%;
height: 100%;
object-fit: cover;
}
@media (max-width: 768px) {
.hero-container {
grid-template-columns: 1fr;
text-align: center;
gap: 2rem;
}
.hero-title {
font-size: 2.5rem;
}
.image-placeholder {
width: 300px;
height: 300px;
}
}
</style>
src/components/About.vue
vue
<template>
<section id="about" class="about">
<div class="container">
<h2 class="section-title">About Me</h2>
<div class="about-content">
<div class="about-text">
<p>
I'm a passionate full-stack developer with over 3 years of experience
creating digital solutions that make a difference. I specialize in
modern web technologies and love turning complex problems into
simple, beautiful designs.
</p>
<p>
When I'm not coding, you can find me exploring new technologies,
contributing to open-source projects, or enjoying a good cup of coffee
while reading about the latest industry trends.
</p>
<div class="stats">
<div class="stat">
<h3>50+</h3>
<p>Projects Completed</p>
</div>
<div class="stat">
<h3>3+</h3>
<p>Years Experience</p>
</div>
<div class="stat">
<h3>20+</h3>
<p>Happy Clients</p>
</div>
</div>
</div>
</div>
</div>
</section>
</template>
<script>
export default {
name: 'About'
}
</script>
<style scoped>
.about {
padding: 100px 0;
background: #f8f9fa;
}
.container {
max-width: 1200px;
margin: 0 auto;
padding: 0 2rem;
}
.section-title {
text-align: center;
font-size: 2.5rem;
margin-bottom: 3rem;
color: #2c3e50;
}
.about-content {
max-width: 800px;
margin: 0 auto;
}
.about-text p {
font-size: 1.1rem;
margin-bottom: 1.5rem;
color: #666;
line-height: 1.8;
}
.stats {
display: grid;
grid-template-columns: repeat(3, 1fr);
gap: 2rem;
margin-top: 3rem;
}
.stat {
text-align: center;
padding: 2rem;
background: white;
border-radius: 10px;
box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
}
.stat h3 {
font-size: 2.5rem;
color: #3498db;
margin-bottom: 0.5rem;
}
.stat p {
color: #666;
font-weight: 500;
}
@media (max-width: 768px) {
.stats {
grid-template-columns: 1fr;
}
}
</style>
src/components/Skills.vue
vue
<template>
<section id="skills" class="skills">
<div class="container">
<h2 class="section-title">Skills & Technologies</h2>
<div class="skills-grid">
<div class="skill-category">
<h3>Frontend</h3>
<div class="skill-items">
<span class="skill-item">Vue.js</span>
<span class="skill-item">React</span>
<span class="skill-item">JavaScript</span>
<span class="skill-item">TypeScript</span>
<span class="skill-item">HTML5</span>
<span class="skill-item">CSS3</span>
<span class="skill-item">Sass</span>
</div>
</div>
<div class="skill-category">
<h3>Backend</h3>
<div class="skill-items">
<span class="skill-item">Node.js</span>
<span class="skill-item">Express</span>
<span class="skill-item">Python</span>
<span class="skill-item">Django</span>
<span class="skill-item">PostgreSQL</span>
<span class="skill-item">MongoDB</span>
</div>
</div>
<div class="skill-category">
<h3>Tools & Others</h3>
<div class="skill-items">
<span class="skill-item">Git</span>
<span class="skill-item">Docker</span>
<span class="skill-item">AWS</span>
<span class="skill-item">Figma</span>
<span class="skill-item">Webpack</span>
<span class="skill-item">Jest</span>
</div>
</div>
</div>
</div>
</section>
</template>
<script>
export default {
name: 'Skills'
}
</script>
<style scoped>
.skills {
padding: 100px 0;
background: white;
}
.container {
max-width: 1200px;
margin: 0 auto;
padding: 0 2rem;
}
.section-title {
text-align: center;
font-size: 2.5rem;
margin-bottom: 3rem;
color: #2c3e50;
}
.skills-grid {
display: grid;
grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
gap: 2rem;
}
.skill-category {
background: #f8f9fa;
padding: 2rem;
border-radius: 10px;
text-align: center;
}
.skill-category h3 {
font-size: 1.5rem;
margin-bottom: 1.5rem;
color: #2c3e50;
}
.skill-items {
display: flex;
flex-wrap: wrap;
gap: 0.5rem;
justify-content: center;
}
.skill-item {
background: #3498db;
color: white;
padding: 0.5rem 1rem;
border-radius: 20px;
font-size: 0.9rem;
font-weight: 500;
}
</style>
src/components/Projects.vue
vue
<template>
<section id="projects" class="projects">
<div class="container">
<h2 class="section-title">Featured Projects</h2>
<div class="projects-grid">
<div class="project-card" v-for="project in projects" :key="project.id">
<div class="project-image">
<img :src="project.image" :alt="project.title" />
<div class="project-overlay">
<div class="project-links">
<a :href="project.demo" target="_blank" class="