Empresas
Empleos
  • Sobre nosotros
  • Soluciones
    • Publicación de vacantes
      Publica tu vacante y recibe candidatos calificados en 48h.
    • Evaluación de candidatos
      500+ pruebas técnicas y psicológicas, más anti-fraude.
    • Headhunting
      Búsqueda ejecutiva a la medida de principio a fin.
    • Nómina + EOR
      Dispersión de nómina y EOR en más de 15 países de LATAM.
  • Precios
  • Empleos

0

108
Vistas
Using Scroll on bootstrap

I want to implement scroll in bootstrap on my child component (ProductList.vue). Can anyone help me how to paste the code in boostrap 5? I've looked for the problem but haven't found it yet. This is my bootstrap 5 code on child component (ProductList.vue)


    <template>
        <div class="row d-flex justify-content-center">
          <div
            class="card text-center card-wrapper"
            style="width: 18rem"
            v-for="product in products"
            :key="product.item"
          >
            <img class="p-2" style="max-height:200px; height:100%" :src="product.imgUrl" alt="product.title" />
            <div class="card-body ">
              <h5 class="card-title text-truncate">{{ product.title }}</h5>
              <p class="card-text">$ {{ product.price }}</p>
              <a href="#" class="btn btn-primary">Add to cart</a>
            </div>
          </div>
        </div>
    </template>
    
    <script>
    import products from "../item/product.json";
    export default {
      name: "ProduckList",
      data() {
        return {
          products,
        };
      },
    };
    </script>
    
    <style scoped>
        .card-wrapper {
          background-color: rgb(149, 211, 247);
        }
    </style>

this is on parent component (App.vue)


    <template>
      <Header />
        <div class="row">
          <div class="col-8">
              <produck-list />
          </div>
          <div class="col-4">
            <Cart />
          </div>
      </div>
    </template>
    
    <script>
    import Header from "./components/Header.vue";
    import ProduckList from "./components/ProductList.vue";
    import Cart from "./components/Cart.vue";
    export default {
      components: {
        Header,
        ProduckList,
        Cart,
      },
    };
    </script>
    
    <style>
      body {
            background-color: rgb(13, 30, 37)!important;
          }
    </style>

I want the results of cards to be scrollable like this https://getbootstrap.com/docs/5.0/utilities/overflow/

about 4 years ago · Juan Pablo Isaza
1 Respuestas
Responde la pregunta

0

It seems that you haven't added the overflow-auto short hand to your top div, perhaps editing your top div as follows may help.

<div class="row d-flex justify-content-center overflow-auto">

about 4 years ago · Juan Pablo Isaza Denunciar
Responde la pregunta
Encuentra empleos remotos

¡Descubre la nueva forma de encontrar empleo!

Top de empleos
Top categorías de empleo
Empresas
Publicar vacante Precios Comercial
Legal
Términos y condiciones Política de privacidad
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Recomiéndame algunas ofertas
Necesito ayuda