Introduction
Meteor is an ultra-simple environment for building modern websites. What once took weeks, even with the best tools, now takes hours with Meteor.
The web was originally designed to work in the same way that mainframes worked in the 70s. The application server rendered a screen and sent it over the network to a dumb terminal. Whenever the user did anything, that server rerendered a whole new screen. This model served the Web well for over a decade. It gave rise to LAMP, Rails, Django, PHP.
But the best teams, with the biggest budgets and the longest schedules, now build applications in JavaScript that run on the client. These apps have stellar interfaces. They don’t reload pages. They are reactive: changes from any client immediately appear on everyone’s screen.
They’ve built them the hard way. Meteor makes it an order of magnitude simpler, and a lot more fun. You can build a complete application in a weekend, or a sufficiently caffeinated hackathon. No longer do you need to provision server resources, or deploy API endpoints in the cloud, or manage a database, or wrangle an ORM layer, or swap back and forth between JavaScript and Ruby, or broadcast data invalidations to clients.
Start
Install
Linux / Mac OS :
curl https://install.meteor.com/ | sh
Create App
$ meteor create myapp
Run it locally:
$ cd myapp
$ meteor
# Meteor server running on: http://localhost:3000/
Unleash it on the world (on a free server we provide):
$ meteor deploy myapp.meteor.com
Principles of Meteor
1. Data on the Wire. Meteor doesn't send HTML over the network. The server sends data and lets the client render it.
2. One Language. Meteor lets you write both the client and the server parts of your application in JavaScript.
3. Database Everywhere. You can use the same methods to access your database from the client or the server.
4. Latency Compensation(延迟补偿). On the client, Meteor prefetches data and simulates models to make it look like server method calls return instantly.
5. Full Stack Reactivity. In Meteor, realtime is the default. All layers, from database to template, update themselves automatically when necessary.
6. Embrace the Ecosystem. Meteor is open source and integrates with existing open source tools and frameworks.
7. Simplicity Equals Productivity. The best way to make something seem simple is to have it actually be simple. Meteor's main functionality has clean, classically beautiful APIs.