File tree Expand file tree Collapse file tree 3 files changed +9
-7
lines changed
add-ons/start/assets/src/routes Expand file tree Collapse file tree 3 files changed +9
-7
lines changed Original file line number Diff line number Diff line change @@ -42,7 +42,7 @@ function Home() {
4242 } }
4343 class = "bg-blue-500 hover:bg-blue-700 text-white font-bold py-2 px-4 rounded"
4444 >
45- Add 1 to { state } ?
45+ Add 1 to { state ( ) } ?
4646 </ button >
4747 </ div >
4848 )
Original file line number Diff line number Diff line change 11import { createFileRoute } from "@tanstack/solid-router";
2+ import { For } from "solid-js"
23<% if (! tailwind) { % >
34import logo from " ../logo.svg" ;
45import " ../App.css" ;
@@ -97,16 +98,17 @@ return (
9798
9899 < section class = " py-16 px-6 max-w-7xl mx-auto" >
99100 < div class = " grid grid-cols-1 md:grid-cols-2 lg:grid-cols-3 gap-6" >
100- { features . map (( feature , index ) => (
101- < div
102- key = " {index} "
101+ < For each = {features} >
102+ {( feature ) => (
103+ < div
103104 class = " bg-slate-800/50 backdrop-blur-sm border border-slate-700 rounded-xl p-6 hover:border-cyan-500/50 transition-all duration-300 hover:shadow-lg hover:shadow-cyan-500/10"
104105 >
105106 < div class = " mb-4" > {feature .icon }< / div>
106107 < h3 class = " text-xl font-semibold text-white mb-3" > {feature .title }< / h3>
107108 < p class = " text-gray-400 leading-relaxed" > {feature .description }< / p>
108109 < / div>
109- ))}
110+ )}
111+ < / For>
110112 < / div>
111113 < / section>
112114< / div>
You can’t perform that action at this time.
0 commit comments