This new release features a few major breaking changes for Telescope. Make sure you read through!

First, here’s a video overview of the main changes:

Should You Update?

As I said, this update contains a few breaking, non-backwards compatible changes. So before updating with meteor update or by pulling from the Telescope repo, please read through the whole changelog and make sure the update won’t break any critical features in your app!

Meteor 1.2

Telescope now runs on Meteor 1.2. The main consequence is that the new version might be incompatible with packages and themes that haven’t been updated yet.

As far as themes and packages are concerned, the main incompatible change is that static assets (such as images) are not included in packages via addFile anymore, but via addAssets instead. You’ll find a full list of Meteor 1.2 changes here.

FlowRouter

The other big change is the switch from Iron Router to FlowRouter.

In order to make the migration quicker, I decided to simplify Telescope’s routing architecture by getting rid of the /top, /best, /new, etc. views. Don’t worry, the various views are still available, but they’re now driven by URL query parameters (?view=top) instead of separate routes.

If this turns out to be an issue for existing apps, I will accept PRs to add route aliases for these views.

So why switch in the first place? Despite both being advertised as “routers”, Iron Router and FlowRouter do very different things. While Iron Router also handled subscription and data management, FlowRouter focuses on routing exclusively.

This means pushing out a lot of logic into different parts of your app (namely, template controllers) and, in a way, taking a step back towards a less organized codebase. But in practice, it’s also a lot easier to manage. As it turns out, it’s just best to spread complexity around rather than try and do to much in one place.

Filtering

Finally, from a features standpoint the big improvement is filtering. Each Telescope parameter (post view, category, search query, etc.) can now be combined simultaneously. This means you can now search within a category, rank these search results by score or date posted, and even (although it’s not exposed yet in the UI) limit the results to a specific time period.

Used in combination with category filtering, this means you can now use Telescope as a powerful directory or search engine for large amounts of content.

Spiderable

Some people have reported issues with Meteor’s own Spiderable rendering package, used to render a copy of the sites for bots and crawlers. So I’ve extracted the dependency out to is own telescope:spiderable package to make it easier to remove it.

This means that if you’re upgrading from an older version of Telescope and want to keep using Spiderable, you’ll need to add telescope:spiderable to your list of packages with meteor add telescope:spiderable.

The Single Day Package

The telescope:singleday package has been removed from Telescope to make releasing the new version easier, so you’ll need to remove it from your own package list with meteor remove telescope:singleday.

Full Changelog

Meteor 1.2

  • Updated for Meteor 1.2

Flow Router

  • Switched from Iron Router to Flow Router.
  • Moved auth/permission logic from router to templates.
  • Removed /top, /new, /best, etc. routes.

Categories

  • New category filter mode.
  • New settings option to switch between regular categories and filter categories.
  • On post edit page, auto-expand selected categories.
  • On post submission, auto-add all parents of all selected categories.
  • Now including posts from children categories in posts category count.
  • Added option for auto-hiding empty categories.
  • In category menu, expand category tree to show active categories.

Other New Features

  • New post approval/rejection workflow: pending posts can be approved or rejected; approved posts can only be rejected; rejected posts can only be approved.
  • Added approved/reject/delete buttons to post item actions.
  • Added rejected view to show all rejected posts.
  • Posts.parameters.get now iterates over the postsParameters callback hook to build parameters object.
  • Comments.parameters.get now iterates over the commentsParameters callback hook to build parameters object.
  • RSS feed and API can now both accept any post query parameter (limit, view, cat, before, after, etc.)
  • Now passing current user ID to Posts.parameters.get query constructor.
  • Added afterEmbedlyPrefill callback hook on client.
  • Removing a user now gives the option to remove their posts and comments, too.

Renamings

  • postApprovedAsync hook renamed to postApproveAsync, added postRejectAsync.
  • Changed Posts.getSubParams to Posts.parameters.get.
  • Changed Comments.getSubParams to Comments.parameters.get.

Removals

  • Removed Telescope.utils.getCurrentTemplate();
  • Removed search logging.
  • Disabled single day view.
  • Posts.checkForSameUrl doesn’t auto-upvote the existing post anymore.
  • Removed delete link from post edit page.

Menu Component

  • Menu item custom data context is now passed as item.data.
  • Add nesting level CSS class to menu items.

Other Changes

  • Moved schema i18n to collection level.
  • Use Users.adminUsers more consistently.
  • Upvote/downvote functions now take document _id as argument, not document object itself.
  • Using tmeasday:publish-counts to publish posts category counts (instead of denormalizing).
  • Fixed delay on post submission.
  • Updated category_title template to handle multiple categories.
  • Fixed Subscribe to Comments feature.
  • Fixed Safari CSS issues by enabling autoprefixer.

i18n

  • Korean translation.
  • Slovenian translation.
  • Italian translation.