Appearance
Edit content
Almost all text in a template lives in src/data/content.js (some templates split it into several files in src/data/). Change a value, save, and the page updates while npm run dev is running.
What the data file looks like
Content is plain JavaScript objects and arrays, one export per section:
js
import { img, photos as p } from '../lib'
export const brand = {
name: 'Aurelia',
email: '[email protected]',
phone: '+1 (310) 555-0148',
}
export const nav = [
{ label: 'Home', href: '#home' },
{ label: 'Services', href: '#services' },
{ label: 'About Us', href: '#about' },
]
export const hero = {
text: 'Discover hand-picked properties, expert agents, and a seamless journey to your perfect place.',
sideImage: img(p.modernWhiteBrick2, 700),
}Step by step
- Start with
brand: your business name, email, phone and address. These appear in the navbar, footer and contact section. - Work down the file section by section. The export names match the sections (
hero,services,testimonials,faq…), in the same order as the page. - Edit only the values between quotes. Keep the commas, brackets and keys.
- Save. The browser updates. If it goes blank, check the terminal for a syntax error (usually a missing comma or quote).
Find any text fast
Not sure where a sentence comes from? Search the whole project for it. In VS Code, Ctrl + Shift + F (Cmd + Shift + F on macOS). A few short labels (button text, headings) are written directly in the section component in src/components/sections/.
Lists: adding and removing items
Cards, team members, prices, reviews and FAQs are arrays. Copy an item to add one, delete an item to remove it:
js
export const testimonials = [
{ name: 'Amina J.', role: 'Bought in Dar es Salaam', quote: 'Smooth from start to finish.', rating: 5 },
{ name: 'David K.', role: 'Sold in Arusha', quote: 'Sold in three weeks.', rating: 5 },
// ↓ added
{ name: 'Neema M.', role: 'First-time buyer', quote: 'They explained everything.', rating: 5 },
]Layouts adapt to the number of items, but grids look best with the same count as the demo (or a multiple of the column count).
Writing special characters
- Quotes inside text: use the other kind of quote around the value, or a backslash:
"It's ready"or'It\'s ready'. - Long text over several lines: use backticks (template literals):
text: `Line one and line two`. - Accents, Swahili and other languages work as is:
'Karibu sana'.
Links and contact details
- Anchor links (
#contact) scroll to the section whoseidmatches. Section IDs are defined insections.config.js. - Phone links:
href: 'tel:+255700000000'. - Email links:
href: 'mailto:[email protected]'. - WhatsApp:
href: 'https://wa.me/255700000000'(country code, no+or spaces). - External links: a full
https://URL.
Prices and currencies
Prices are stored as numbers or strings in the data file. Change the currency symbol where the price is displayed (search for $ in src/components/), or store the formatted price as text, for example price: 'TSh 450,000'.
Forms
Contact, booking and newsletter forms work in the browser (validation, success state) but don't send anything yet, because a static site has no server. To receive submissions, point the form at a form service such as Formspree, Web3Forms, Basin or Netlify Forms, following that service's instructions. The form component is in src/components/sections/ (for example Contact.jsx).
Use the copywriting prompts
prompts/COPYWRITING.md has a ready AI prompt for every section that respects the space each text has in the design. See Copywriting prompts.