You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
reacted with thumbs up emoji reacted with thumbs down emoji reacted with laugh emoji reacted with hooray emoji reacted with confused emoji reacted with heart emoji reacted with rocket emoji reacted with eyes emoji
-
hi , i want to create dynamically my indicators buttons in a map loop
props.data.map((slide, index) => (
<button
type="button"
key={index}
data-bs-target={"#" + props.id}
{...(index === 0 && { className: "active" })}
{...(index === 0 && { "aria-current": "true" })}
aria-label={slide.title}
data-bs-slide={index}
>
))}
when i lookinto the html source in the browser, the carousel, removes the class "active" but doesn't add it on the next slide
everything is ok, if the indicators are not dynamicaly created
Beta Was this translation helpful? Give feedback.
All reactions