Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 6209187
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 24, 20262026-05-24T05:56:25+00:00 2026-05-24T05:56:25+00:00

Hi all I am creating my first Backbone.js app. It is basically a collection

  • 0

Hi all I am creating my first Backbone.js app. It is basically a collection that renders the data in a table. What I want to do is to be able to filter and sort data.
What is the best way to do it? Should I use the Router or store some params that render will take into consideration.

I think the Router will get really complex soon as I am going to have 3-4 filters and 1 order option.

What do you think?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-24T05:56:26+00:00Added an answer on May 24, 2026 at 5:56 am

    I would add methods on my collections for the filtering and sorting, and using a view to just render an arbitrary collection, that might be filtered or ordered.

    For ordering there is a built in hook: http://documentcloud.github.com/backbone/#Collection-comparator

    For filtering, check out the underscore helper methods on collections, and extend with your own.

    You could for example have a collection.doFiltering([filter1, filter2, filter3]);
    that returns a filtered array.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have a C# Application I am creating that stores all data in SQL
I'm creating my first android application but it does not start at all. In
I'm creating my first rails app, and using the standard prototype library for some
I am creating my first tab controller app. I have 2 tabs with 2
I'm creating my first android app (or attempting to anyway) and i have a
I just started creating my first WP theme after doing the HTML/CSS. All good
First of all let me say that this questions is slightly connected to another
I'm creating a program that installs a keyboard hook to capture all keys and
I'm creating my first Spring MVC app on Tomcat 6. Certain pages will be
I am currently creating my first project using Google App Engine in Eclipse. For

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.