question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

QTable global default pagination values

See original GitHub issue

Quasar is hardcoded to show 5 rows per page by default. I’d like to bump the default up to, let’s say, 10. How can I do this globally without having to define rowsPerPage: 10 over and over again?

Issue Analytics

  • State:closed
  • Created 4 years ago
  • Comments:10 (6 by maintainers)

github_iconTop GitHub Comments

1reaction
Propaganistascommented, Dec 29, 2019

Thanks @metalsadman . How’d you proxy all bindings, listeners and slots down to the actual QTable component?

I found this on SO?

<template>
  <q-table v-bind="$attrs" v-on="$listeners">

    <template v-for="(_, slot) of $scopedSlots" v-slot:[slot]="scope">
        <slot :name="slot" v-bind="scope"/>
    </template>

  </q-table>
</template>
0reactions
ajcastrocommented, Jan 14, 2020

you can also create a Factory that will return the pagination object and use it in your component

import PaginationFactory from 'where/you/put/your/PaginationFactory';

export default {
  data() {
    return {
      pagination: PaginationFactory.make({
        // we can pass some pagination props that can override the default pagination props
      })
    };
  }
}
Read more comments on GitHub >

github_iconTop Results From Across the Web

How to implement Quasar q-table with server-side pagination?
I am trying to implement server-side pagination for a Quasar QTable, using Vuex and Django Rest Framework as the backend.
Read more >
Table: Pagination with initial sort and rows per page - CodePen
https://quasar.dev/vue-components/table#Example--Pagination-with-initial-sort-and-rows-per-page. 4. -->. 5. <div id="q-app">. 6. <div class="q-pa-md">.
Read more >
Data Table - Quasar Framework
Internationalization. The default values of the different QTable labels are taken care of by default through Quasar I18n. If your desired ...
Read more >
Quasar's QTable: The ULTIMATE Component (3/6) - Loading ...
You already know what loading state, pagination and sorting is. ... from 'axios' export default defineComponent({ setup () { const loading ...
Read more >
API Reference — django-tables2 2.3.1 documentation
A dict can be used to specify default values for the call to paginate (e.g. to define ... Provides a way to define...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found