Building Single-page Web Apps with Meteor
eBook - ePub

Building Single-page Web Apps with Meteor

Fabian Vogelsteller

Partager le livre
  1. 198 pages
  2. English
  3. ePUB (adapté aux mobiles)
  4. Disponible sur iOS et Android
eBook - ePub

Building Single-page Web Apps with Meteor

Fabian Vogelsteller

DĂ©tails du livre
Aperçu du livre
Table des matiĂšres
Citations

Foire aux questions

Comment puis-je résilier mon abonnement ?
Il vous suffit de vous rendre dans la section compte dans paramĂštres et de cliquer sur « RĂ©silier l’abonnement ». C’est aussi simple que cela ! Une fois que vous aurez rĂ©siliĂ© votre abonnement, il restera actif pour le reste de la pĂ©riode pour laquelle vous avez payĂ©. DĂ©couvrez-en plus ici.
Puis-je / comment puis-je télécharger des livres ?
Pour le moment, tous nos livres en format ePub adaptĂ©s aux mobiles peuvent ĂȘtre tĂ©lĂ©chargĂ©s via l’application. La plupart de nos PDF sont Ă©galement disponibles en tĂ©lĂ©chargement et les autres seront tĂ©lĂ©chargeables trĂšs prochainement. DĂ©couvrez-en plus ici.
Quelle est la différence entre les formules tarifaires ?
Les deux abonnements vous donnent un accĂšs complet Ă  la bibliothĂšque et Ă  toutes les fonctionnalitĂ©s de Perlego. Les seules diffĂ©rences sont les tarifs ainsi que la pĂ©riode d’abonnement : avec l’abonnement annuel, vous Ă©conomiserez environ 30 % par rapport Ă  12 mois d’abonnement mensuel.
Qu’est-ce que Perlego ?
Nous sommes un service d’abonnement Ă  des ouvrages universitaires en ligne, oĂč vous pouvez accĂ©der Ă  toute une bibliothĂšque pour un prix infĂ©rieur Ă  celui d’un seul livre par mois. Avec plus d’un million de livres sur plus de 1 000 sujets, nous avons ce qu’il vous faut ! DĂ©couvrez-en plus ici.
Prenez-vous en charge la synthÚse vocale ?
Recherchez le symbole Écouter sur votre prochain livre pour voir si vous pouvez l’écouter. L’outil Écouter lit le texte Ă  haute voix pour vous, en surlignant le passage qui est en cours de lecture. Vous pouvez le mettre sur pause, l’accĂ©lĂ©rer ou le ralentir. DĂ©couvrez-en plus ici.
Est-ce que Building Single-page Web Apps with Meteor est un PDF/ePUB en ligne ?
Oui, vous pouvez accĂ©der Ă  Building Single-page Web Apps with Meteor par Fabian Vogelsteller en format PDF et/ou ePUB ainsi qu’à d’autres livres populaires dans Computer Science et Web Development. Nous disposons de plus d’un million d’ouvrages Ă  dĂ©couvrir dans notre catalogue.

Informations

Année
2015
ISBN
9781783988129

Building Single-page Web Apps with Meteor


Table of Contents

Building Single-page Web Apps with Meteor
Credits
About the Author
Acknowledgments
About the Reviewers
www.PacktPub.com
Support files, eBooks, discount offers, and more
Why subscribe?
Free access for Packt account holders
Preface
What this book covers
What you need for this book
Who this book is for
Conventions
Reader feedback
Customer support
Downloading the example code
Errata
Piracy
Questions
1. Getting Started with Meteor
The full-stack framework of Meteor
Meteor's requirements
Using Chrome's developer tools
Using Git and GitHub
Installing Meteor
Installing Git
Creating our first app
Creating a good folder structure
Preadd style files
Adding basic packages
Adding a core package
Adding a third-party package
Variable scopes
Meteor's folder conventions and loading order
Loading assets on the server
Meteor's command-line tool
Updating Meteor
Deploying Meteor
Summary
2. Building HTML Templates
Writing templates in Meteor
Building the basic templates
Adding templates and partials
Displaying data with template helpers
Setting the data context for a template
Using the {{#with}} block helper
"this" in template helpers and template callbacks
Adding events
Block helpers
Listing posts
Spacebars syntax
Accessing parent data contexts
Passing data to helpers
Summary
3. Storing Data and Handling Collections
Meteor and databases
Setting up a collection
Adding post examples
Querying a collection
Updating a collection
Database everywhere
Differences between client and server collections
Summary
4. Controlling the Data Flow
Syncing data – the current Web versus the new Web
Removing the autopublish package
Publishing data
Publishing only parts of data
Publishing specific fields
Lazy loading posts
Switching subscriptions
Some notes on data publishing
Summary
5. Making Our App Versatile with Routing
Adding the iron:router package
Setting up the router
Switching to a layout template
Adding another route
Moving the posts subscription to the Home route
Setting up the post route
Creating a single-post publication
Adding the post route
Linking the posts
Changing the website's title
Summary
6. Keeping States with Sessions
Meteor's session object
A better way for simple reactivity
Using sessions in template helpers
Session and hot code pushes
Rerunning functions reactively
Stopping reactive functions
Using autorun in a template
The reactive session object
Summary
7. Users and Permissions
Meteor's accounts packages
Adding the accounts packages
Adding admin functionality to our templates
Adding a link for new posts
Adding the link to edit posts
Adding the login form
Creating the template to edit posts
Creating the admin user
Adding permissions
A note on security
Creating routes for the admin
Preventing visitors from seeing the admin routes
Summary
8. Security with the Allow and Deny Rules
Adding a function to generate slugs
Creating a new post
Saving a post
Editing posts
Updating the current post
Restricting database updates
Removing the insecure package
Adding our first allow rules
Adding a deny rule
Adding posts using a method call
Method stubs and latency compensation
Changing the button
Adding the method
Calling the method
Summary
9. Advanced Reactivity
Reactive programming
The invalidating cycle
Building a simple reactive object
Rerunning functions
Creating an advanced timer object
Reactive computations
Stopping reactive functions
Preventing run at start
Advanced reactive objects
Summary
10. Deploying Our App
Deploying on meteor.com
Deploying on meteor.com using a domain name
Backup and restore databases hosted on meteor.com
Deploying on other servers
Bundling our app
Deploying using Demeteorizer
Deploying using Meteor Up
Setting up the server
Deploying with mup
Outlook
Summary
11. Building Our Own Package
The structure of a package
Creating our own package
Adding the package metadata
Adding the package
Releasing our package to the public
Publishing our package online
Updating our package
Summary
12. Testing in Meteor
Types of tests
Testing packages
Adding package tests
Running the package tests
Testing our meteor app
Testing using Jasmine
Adding unit tests to the server
Adding integration tests to the client
Adding a test for the visitors
Adding a test for the admin
Acceptance tests
Nightwatch
Laika
Summary
A. Appendix
List of Meteor's command-line tool commands
The iron:router hooks
Index

Building Single-page Web Apps with Meteor

Copyright © 2015 Packt Publishing
All rights reserved. No part of this book may be reproduced, stored in a retrieval system, or transmitted in any form or by any means, without the prior written permission of the publisher, except in the case of brief quotations embedded in critical articles or reviews.
Every effort has been made in the preparation of this book to ensure the accuracy of the information presented. However, the information contained in this book is sold without warranty, either express or implied. Neither the author, nor Packt Publishing, and its dealers and distributors will be held liable for any damages caused or alleged to be caused directly or indirectly by this bo...

Table des matiĂšres