Submitted over 1 year ago
Responsive Intro Section Page using Svelte, TS, and Tailwind
@fredcamp
Design comparison
SolutionDesign
Solution retrospective
Instead of using svgs as images, with Svelte we can directly use them as Svelte Component Icon by changing .svg into .svelte and export them together with the links so that we can both use them for the Navbar Component.
import TodoIcon from '../icons/icon-todo.svelte'
import CalendarIcon from '../icons/icon-calendar.svelte'
import ReminderIcon from '../icons/icon-reminders.svelte'
import PlanningIcon from '../icons/icon-planning.svelte'
export function createLinks() {
return [
{
page: 'Features',
links: [
{
Icon: TodoIcon,
page: 'Todo List',
},
{
Icon: CalendarIcon,
page: 'Calendar',
},
{
Icon: ReminderIcon,
page: 'Reminders',
},
{
Icon: PlanningIcon,
page: 'Planning',
},
],
},
]
}
Community feedback
Please log in to post a comment
Log in with GitHubJoin our Discord community
Join thousands of Frontend Mentor community members taking the challenges, sharing resources, helping each other, and chatting about all things front-end!
Join our Discord