Do What I Mean

Meteor overview and major packages (deprecated)

Table of Contents

This repository contains a brief overview of Meteor and an list of its major packages. Meteor is an innovative platform for developing web-apps. The following features distinguish Meteor from other web-platforms:

These are impressive Unique Selling Points, but in the end it turned out to be too much (at least it was to me). There are just too many moving parts. So, since 2017Q4 I haven't worked with Meteor. It's premises are a developer's dream, but I always struggled to get a stable app.

1 Overview

The mindmap below shows how I understand Meteor:

Meteor mindmap

The client handles routing and rendering. Routing is taken care of by Flow router, which uses Blaze as template engine (Angular and React are also supported). Templates are divided in three layers:

  • layouts define the general structure of your site, using pages
  • pages are smart, which means they collect data and feed them to components
  • components do not interact with anything except though parameters, which makes them highly reusable

Templates can be controlled through helpers and event handlers (including onCreated).

The server uses Mongodb as a datastore. Data is stored in collections, which are basically persistent JSON documents. A schema language is used to define the datastructures, so data can be validated. Schema also drive the autoform package. Collections can be controlled through helpers and hooks.

The client and server communicate through a publish/subscribe mechanism and through methods. The server controls data access by selectively publishing data to the client. The client (pages) collect data through subscriptions. Methods are Meteor's remote procedure calls (RPCs) and can use schema for data validation.

Some final tips & tricks:

  • waitOn (package Iron Router) lets you defer execution untill a subscription has finished
  • Meteor methods <i>can</i> be called synchronously on the server, but <i>must</i> be called asynchronously on the client
  • Global variables aren't available from templates. Access them with template helper.
  • add c:\Windows\System32 to path on tasklist.exe error
  • The autorun function lets you define a function that is run automatically when a reactive data source changes.

2 Packages

Just like all other modern frameworks, Meteor relies heavily on third party packages from its thriving eco-system. The Meteor Guide gives an opinionated overview of which packages to use. The table below shows these packages in the middle column, along with some additional packages I prefer in the final column. For more packages visit Atmosphere.js. You can import all these package definitions by importing the file packages from this repository into the file packages of your project and the remove any package you don't need.

<tr><th>subject</th><th>guide</th><th>extra</th></tr>

Out of the box http  
  jQuery  
  markdown  
  meteor:ecmascript  
  underscore  
Collections aldeed:collection2  
  aldeed:simple-schema (jagi:astronomy)  
  dburles:collection-helpers  
  percolate:migrations  
Data-loading percolate:find-from-publication  
  reywood:publish-composite  
  simple:rest  
  tmeasday:publish-counts  
Methods mdg:validated-method  
User accounts alanning:roles didericis:permissions-mixin
  arillo:flow-router-helpers matb33:collection-hooks
  useraccounts:flow-routing ongoworks:security
  useraccounts:core ostrio:user-status
  useraccounts:unstyled (or tmeasday:presence)
Routing arillo:flow-router-helpers ostrio:flow-router-extra
  kadira:flow-router  
  kadira:blaze-layout  
  nimble:restivus  
  zimme:active-route  
UI-UX aldeed:autoform aldeed:tabular
  percolate:momentum aldeed:template-extension
  tap:i18n (or universe:18n) aslagle:reactive-table
    chrismbeckett:toastr
    fortawesome:fontawesome
    matb33:bootstrap-glyphicons
    raix:push
    semantic:ui
    twbs:bootstrap
Other dburles:google-maps  
  easy:search  
  momentjs:moment  
  sach:flow-db-admin  
Testing dburles:factory Chimp (not really a package)
  hwillson:stub-collections  
  johanbrook:publication-collector  
  meteortesting:mocha  
  practicalmeteor:mocha  
  velocity:meteor-stubs  
  xolvio:cleaner  
Deployment dferber:prerender  
  kadira:dochead  
  mdg:seo  
  okgrow:analytics  
©2019 otech-nl