SlideShare a Scribd company logo
1 of 12
Download to read offline
TodoAppwith Meteor
» Long Nguyen
» @vangnol
Whatis Meteor?
Meteor is a framework for building incredible web
application. Meteor helps you build complex web
application but in minimal amount of time. It's full-
stack framework. On the server it runs on Nodejs,
which means Meteor written in Javascript. Meteor has
out of the box integration with MongoDB database.
Meteor uses DDP Protocal to communicate between
client and server.
Setup
» MacOS or Ubuntu
curl https://install.meteor.com/ | sh
» Windows
Go get a Mac or a Ubuntu laptop
Demo
Simple Todo App with Meteor
♡♡♡
task.html
<head>
<title>Simple Todo App</title>
</head>
<body>
<h1>Awesome Todo App</h1>
<hr/>
<div class="container">
{{> CreateTask}}
{{> ListTasks}}
{{> CompleteCounter}}
</div>
</body>
<template name="ListTasks">
<ul>
{{#each tasks}}
<li class="task {{doneClass}}">{{> Task}}</li>
{{/each}}
</ul>
</template>
<template name="Task">
<input type="checkbox" name="is_done" {{isDoneChecked}} />
{{subject}}
</template>
<template name="CreateTask">
<form class="create-task" >
<input type="text" placeholder="Creating new task...!" />
</form>
</template>
<template name="CompleteCounter">
<h3>{{completeTask}} / {{totalTasks}} tasks completed</h3>
</template>
task.css
.task{
font-size: 20px;
background-color: #EBEBEB;
padding: 10px;
margin-bottom: 2px;
}
.done{
text-decoration: line-through;
}
task.js
Todos = new Meteor.Collection('todos');
if(Meteor.isClient){
Template.ListTasks.helpers({
tasks: function(){
return Todos.find();
},
doneClass: function(){
return this.is_done ? 'done' : '';
}
});
Template.Task.helpers({
isDoneChecked: function(){
return this.is_done ? 'checked' : ''
}
});
Template.Task.events({
"click [name=is_done]": function(e, tmpl){
var id = this._id;
var isDone = tmpl.find('input').checked;
Todos.update({_id: id}, {$set: { is_done: isDone}});
}
});
Template.CreateTask.events({
'submit form': function(e, tmpl){
e.preventDefault();
var subject = tmpl.find('input').value;
Todos.insert({subject: subject, created_at: new Date, is_done: false});
var form = tmpl.find('form');
form.reset();
}
});
}
Template.CompleteCounter.helpers({
completeTask: function(){
return Todos.find({is_done: true}).count();
},
totalTasks: function(){
return Todos.find({}).count();
}
});
}
if(Meteor.isServer){
}
References
» MeteorHacks
» Best Learning Resources
» Meteor Packages
» Why Meteor will kill Ruby on Rails
» Meteor Won’t Kill Rails Anytime Soon
» How to Learn JavaScript Properly
Thankyou!

More Related Content

What's hot

Robust web apps with React.js
Robust web apps with React.jsRobust web apps with React.js
Robust web apps with React.jsMax Klymyshyn
 
Getting started with node JS
Getting started with node JSGetting started with node JS
Getting started with node JSHamdi Hmidi
 
Meteor Day Athens (2014-11-07)
Meteor Day Athens (2014-11-07)Meteor Day Athens (2014-11-07)
Meteor Day Athens (2014-11-07)svub
 
Qtp Tutorial 4 Recording Of Tests In Qtp With Drag And Drop Web Elements
Qtp Tutorial 4   Recording Of Tests In Qtp With Drag And Drop Web ElementsQtp Tutorial 4   Recording Of Tests In Qtp With Drag And Drop Web Elements
Qtp Tutorial 4 Recording Of Tests In Qtp With Drag And Drop Web ElementsYogindernath Gupta
 
IBM and Node.js - Old Doge, New Tricks
IBM and Node.js - Old Doge, New TricksIBM and Node.js - Old Doge, New Tricks
IBM and Node.js - Old Doge, New TricksDejan Glozic
 
Introduction to ReactJS
Introduction to ReactJSIntroduction to ReactJS
Introduction to ReactJSHoang Long
 
Web Development with NodeJS
Web Development with NodeJSWeb Development with NodeJS
Web Development with NodeJSRiza Fahmi
 
007. Redux middlewares
007. Redux middlewares007. Redux middlewares
007. Redux middlewaresBinh Quan Duc
 
JavaScript innovaties: ECMAScript 6 & 7
JavaScript innovaties: ECMAScript 6 & 7JavaScript innovaties: ECMAScript 6 & 7
JavaScript innovaties: ECMAScript 6 & 7Rick Beerendonk
 
Brad wood - Integrating MVC Into Legacy [Into The Box 2020]
Brad wood - Integrating MVC Into Legacy [Into The Box 2020]Brad wood - Integrating MVC Into Legacy [Into The Box 2020]
Brad wood - Integrating MVC Into Legacy [Into The Box 2020]Ortus Solutions, Corp
 
Building time machine with .net core
Building time machine with .net core Building time machine with .net core
Building time machine with .net core Alper Hankendi
 
Introduction to ReactJS
Introduction to ReactJSIntroduction to ReactJS
Introduction to ReactJSTu Hoang
 
React, Flux and more (p1)
React, Flux and more (p1)React, Flux and more (p1)
React, Flux and more (p1)tuanpa206
 
Enterprise level application in 5 min
Enterprise level application in 5 minEnterprise level application in 5 min
Enterprise level application in 5 minAustin Gil
 
JavaScript Roadmap - DOM Manipulation
JavaScript Roadmap - DOM ManipulationJavaScript Roadmap - DOM Manipulation
JavaScript Roadmap - DOM ManipulationAswin Barath
 

What's hot (20)

Robust web apps with React.js
Robust web apps with React.jsRobust web apps with React.js
Robust web apps with React.js
 
Getting started with node JS
Getting started with node JSGetting started with node JS
Getting started with node JS
 
Meteor Day Athens (2014-11-07)
Meteor Day Athens (2014-11-07)Meteor Day Athens (2014-11-07)
Meteor Day Athens (2014-11-07)
 
Gatling
GatlingGatling
Gatling
 
Qtp Tutorial 4 Recording Of Tests In Qtp With Drag And Drop Web Elements
Qtp Tutorial 4   Recording Of Tests In Qtp With Drag And Drop Web ElementsQtp Tutorial 4   Recording Of Tests In Qtp With Drag And Drop Web Elements
Qtp Tutorial 4 Recording Of Tests In Qtp With Drag And Drop Web Elements
 
IBM and Node.js - Old Doge, New Tricks
IBM and Node.js - Old Doge, New TricksIBM and Node.js - Old Doge, New Tricks
IBM and Node.js - Old Doge, New Tricks
 
Introduction to ReactJS
Introduction to ReactJSIntroduction to ReactJS
Introduction to ReactJS
 
Web Development with NodeJS
Web Development with NodeJSWeb Development with NodeJS
Web Development with NodeJS
 
React JS - Introduction
React JS - IntroductionReact JS - Introduction
React JS - Introduction
 
007. Redux middlewares
007. Redux middlewares007. Redux middlewares
007. Redux middlewares
 
HTML5
HTML5HTML5
HTML5
 
JavaScript innovaties: ECMAScript 6 & 7
JavaScript innovaties: ECMAScript 6 & 7JavaScript innovaties: ECMAScript 6 & 7
JavaScript innovaties: ECMAScript 6 & 7
 
Brad wood - Integrating MVC Into Legacy [Into The Box 2020]
Brad wood - Integrating MVC Into Legacy [Into The Box 2020]Brad wood - Integrating MVC Into Legacy [Into The Box 2020]
Brad wood - Integrating MVC Into Legacy [Into The Box 2020]
 
Building time machine with .net core
Building time machine with .net core Building time machine with .net core
Building time machine with .net core
 
Introduction to ReactJS
Introduction to ReactJSIntroduction to ReactJS
Introduction to ReactJS
 
Introduction to ReactJS
Introduction to ReactJSIntroduction to ReactJS
Introduction to ReactJS
 
React, Flux and more (p1)
React, Flux and more (p1)React, Flux and more (p1)
React, Flux and more (p1)
 
Enterprise level application in 5 min
Enterprise level application in 5 minEnterprise level application in 5 min
Enterprise level application in 5 min
 
Wicket Live on Stage
Wicket Live on StageWicket Live on Stage
Wicket Live on Stage
 
JavaScript Roadmap - DOM Manipulation
JavaScript Roadmap - DOM ManipulationJavaScript Roadmap - DOM Manipulation
JavaScript Roadmap - DOM Manipulation
 

Viewers also liked

AWS Summit Berlin 2013 - Keynote - 6wunderkinder
AWS Summit Berlin 2013 - Keynote - 6wunderkinderAWS Summit Berlin 2013 - Keynote - 6wunderkinder
AWS Summit Berlin 2013 - Keynote - 6wunderkinderAWS Germany
 
Bibstrip Wunderlist - lijstjes maken
Bibstrip Wunderlist - lijstjes makenBibstrip Wunderlist - lijstjes maken
Bibstrip Wunderlist - lijstjes makenKatrien Schroyens
 
Engineering Wunderlist for Android - Ceasr Valiente, 6Wunderkinder
Engineering Wunderlist for Android - Ceasr Valiente, 6WunderkinderEngineering Wunderlist for Android - Ceasr Valiente, 6Wunderkinder
Engineering Wunderlist for Android - Ceasr Valiente, 6WunderkinderDroidConTLV
 
Myriam al dhaheri 201017821 - wunderlist – helps you manage your daily list...
Myriam al dhaheri   201017821 - wunderlist – helps you manage your daily list...Myriam al dhaheri   201017821 - wunderlist – helps you manage your daily list...
Myriam al dhaheri 201017821 - wunderlist – helps you manage your daily list...Myriam Al Dhaheri
 
To Do List Karma - Life style gamification - Manu Melwin Joy
To Do List Karma - Life style gamification - Manu Melwin JoyTo Do List Karma - Life style gamification - Manu Melwin Joy
To Do List Karma - Life style gamification - Manu Melwin Joymanumelwin
 
Todoist iPhone App - Onboarding Roast
Todoist iPhone App - Onboarding RoastTodoist iPhone App - Onboarding Roast
Todoist iPhone App - Onboarding RoastSanket Nadhani
 
Todoist Logo Design Process
Todoist Logo Design ProcessTodoist Logo Design Process
Todoist Logo Design ProcessTodoist
 
How To Grow Your SMS Marketing Database
How To Grow Your SMS Marketing DatabaseHow To Grow Your SMS Marketing Database
How To Grow Your SMS Marketing DatabaseTatango
 
Mobile Means Business
Mobile Means BusinessMobile Means Business
Mobile Means BusinessTack Mobile
 
The Mobile Content Mandate
The Mobile Content MandateThe Mobile Content Mandate
The Mobile Content MandateKaren McGrane
 
The Do's and Dont's of Stellar Push and In-App Messaging: September 2014 Webinar
The Do's and Dont's of Stellar Push and In-App Messaging: September 2014 WebinarThe Do's and Dont's of Stellar Push and In-App Messaging: September 2014 Webinar
The Do's and Dont's of Stellar Push and In-App Messaging: September 2014 WebinarLocalytics
 
Create and Convert Mobile Moments of Truth
Create and Convert Mobile Moments of TruthCreate and Convert Mobile Moments of Truth
Create and Convert Mobile Moments of TruthGreg Hickman
 
Social Action Mobile Marketing
Social Action Mobile MarketingSocial Action Mobile Marketing
Social Action Mobile MarketingWaterfall Mobile
 
Mobile Metrics 101: Everything web marketers need to know about app analytics
Mobile Metrics 101: Everything web marketers need to know about app analyticsMobile Metrics 101: Everything web marketers need to know about app analytics
Mobile Metrics 101: Everything web marketers need to know about app analyticsLocalytics
 
Selling The Mobile Web
Selling The Mobile WebSelling The Mobile Web
Selling The Mobile WebBrad Frost
 

Viewers also liked (20)

AWS Summit Berlin 2013 - Keynote - 6wunderkinder
AWS Summit Berlin 2013 - Keynote - 6wunderkinderAWS Summit Berlin 2013 - Keynote - 6wunderkinder
AWS Summit Berlin 2013 - Keynote - 6wunderkinder
 
Nano Goals App
Nano Goals AppNano Goals App
Nano Goals App
 
Bibstrip Wunderlist - lijstjes maken
Bibstrip Wunderlist - lijstjes makenBibstrip Wunderlist - lijstjes maken
Bibstrip Wunderlist - lijstjes maken
 
Project
ProjectProject
Project
 
Engineering Wunderlist for Android - Ceasr Valiente, 6Wunderkinder
Engineering Wunderlist for Android - Ceasr Valiente, 6WunderkinderEngineering Wunderlist for Android - Ceasr Valiente, 6Wunderkinder
Engineering Wunderlist for Android - Ceasr Valiente, 6Wunderkinder
 
Myriam al dhaheri 201017821 - wunderlist – helps you manage your daily list...
Myriam al dhaheri   201017821 - wunderlist – helps you manage your daily list...Myriam al dhaheri   201017821 - wunderlist – helps you manage your daily list...
Myriam al dhaheri 201017821 - wunderlist – helps you manage your daily list...
 
To Do List Karma - Life style gamification - Manu Melwin Joy
To Do List Karma - Life style gamification - Manu Melwin JoyTo Do List Karma - Life style gamification - Manu Melwin Joy
To Do List Karma - Life style gamification - Manu Melwin Joy
 
Todoist iPhone App - Onboarding Roast
Todoist iPhone App - Onboarding RoastTodoist iPhone App - Onboarding Roast
Todoist iPhone App - Onboarding Roast
 
Todoist Logo Design Process
Todoist Logo Design ProcessTodoist Logo Design Process
Todoist Logo Design Process
 
9 Daily Habits of Entrepreneurs.
9 Daily Habits of Entrepreneurs.9 Daily Habits of Entrepreneurs.
9 Daily Habits of Entrepreneurs.
 
How To Grow Your SMS Marketing Database
How To Grow Your SMS Marketing DatabaseHow To Grow Your SMS Marketing Database
How To Grow Your SMS Marketing Database
 
Empower Customer Engagement with Mobile Context
Empower Customer Engagement with Mobile ContextEmpower Customer Engagement with Mobile Context
Empower Customer Engagement with Mobile Context
 
Mobile Means Business
Mobile Means BusinessMobile Means Business
Mobile Means Business
 
The Mobile Content Mandate
The Mobile Content MandateThe Mobile Content Mandate
The Mobile Content Mandate
 
The Do's and Dont's of Stellar Push and In-App Messaging: September 2014 Webinar
The Do's and Dont's of Stellar Push and In-App Messaging: September 2014 WebinarThe Do's and Dont's of Stellar Push and In-App Messaging: September 2014 Webinar
The Do's and Dont's of Stellar Push and In-App Messaging: September 2014 Webinar
 
Create and Convert Mobile Moments of Truth
Create and Convert Mobile Moments of TruthCreate and Convert Mobile Moments of Truth
Create and Convert Mobile Moments of Truth
 
Social Action Mobile Marketing
Social Action Mobile MarketingSocial Action Mobile Marketing
Social Action Mobile Marketing
 
Mobile Metrics 101: Everything web marketers need to know about app analytics
Mobile Metrics 101: Everything web marketers need to know about app analyticsMobile Metrics 101: Everything web marketers need to know about app analytics
Mobile Metrics 101: Everything web marketers need to know about app analytics
 
Computers
ComputersComputers
Computers
 
Selling The Mobile Web
Selling The Mobile WebSelling The Mobile Web
Selling The Mobile Web
 

Similar to Simple todo app with meteor

Meteor.js Workshop by Dopravo
Meteor.js Workshop by DopravoMeteor.js Workshop by Dopravo
Meteor.js Workshop by DopravoArabNet ME
 
Rob Tweed :: Ajax and the Impact on Caché and Similar Technologies
Rob Tweed :: Ajax and the Impact on Caché and Similar TechnologiesRob Tweed :: Ajax and the Impact on Caché and Similar Technologies
Rob Tweed :: Ajax and the Impact on Caché and Similar Technologiesgeorge.james
 
Frontend microservices: architectures and solutions
Frontend microservices: architectures and solutionsFrontend microservices: architectures and solutions
Frontend microservices: architectures and solutionsMikhail Kuznetcov
 
Javascript MVVM with Vue.JS
Javascript MVVM with Vue.JSJavascript MVVM with Vue.JS
Javascript MVVM with Vue.JSEueung Mulyana
 
Beginning MEAN Stack
Beginning MEAN StackBeginning MEAN Stack
Beginning MEAN StackRob Davarnia
 
Full Stack React Workshop [CSSC x GDSC]
Full Stack React Workshop [CSSC x GDSC]Full Stack React Workshop [CSSC x GDSC]
Full Stack React Workshop [CSSC x GDSC]GDSC UofT Mississauga
 
State of modern web technologies: an introduction
State of modern web technologies: an introductionState of modern web technologies: an introduction
State of modern web technologies: an introductionMichael Ahearn
 
Ta Javaserverside Eran Toch
Ta Javaserverside Eran TochTa Javaserverside Eran Toch
Ta Javaserverside Eran TochAdil Jafri
 
Test Automation for NoSQL Databases
Test Automation for NoSQL DatabasesTest Automation for NoSQL Databases
Test Automation for NoSQL DatabasesTobias Trelle
 
Rest web service_with_spring_hateoas
Rest web service_with_spring_hateoasRest web service_with_spring_hateoas
Rest web service_with_spring_hateoasZeid Hassan
 
Node JS Express: Steps to Create Restful Web App
Node JS Express: Steps to Create Restful Web AppNode JS Express: Steps to Create Restful Web App
Node JS Express: Steps to Create Restful Web AppEdureka!
 
AngularJS for Web and Mobile
 AngularJS for Web and Mobile AngularJS for Web and Mobile
AngularJS for Web and MobileRocket Software
 
CraftCamp for Students - Introduction to Meteor.js
CraftCamp for Students - Introduction to Meteor.jsCraftCamp for Students - Introduction to Meteor.js
CraftCamp for Students - Introduction to Meteor.jscraftworkz
 
Java Script - A New Look
Java Script - A New LookJava Script - A New Look
Java Script - A New Lookrumsan
 
How to Build ToDo App with Vue 3 + TypeScript
How to Build ToDo App with Vue 3 + TypeScriptHow to Build ToDo App with Vue 3 + TypeScript
How to Build ToDo App with Vue 3 + TypeScriptKaty Slemon
 
Magento Performance Optimization 101
Magento Performance Optimization 101Magento Performance Optimization 101
Magento Performance Optimization 101Angus Li
 

Similar to Simple todo app with meteor (20)

code-camp-meteor
code-camp-meteorcode-camp-meteor
code-camp-meteor
 
METEOR 101
METEOR 101METEOR 101
METEOR 101
 
Meteor.js Workshop by Dopravo
Meteor.js Workshop by DopravoMeteor.js Workshop by Dopravo
Meteor.js Workshop by Dopravo
 
Rob Tweed :: Ajax and the Impact on Caché and Similar Technologies
Rob Tweed :: Ajax and the Impact on Caché and Similar TechnologiesRob Tweed :: Ajax and the Impact on Caché and Similar Technologies
Rob Tweed :: Ajax and the Impact on Caché and Similar Technologies
 
Frontend microservices: architectures and solutions
Frontend microservices: architectures and solutionsFrontend microservices: architectures and solutions
Frontend microservices: architectures and solutions
 
Javascript MVVM with Vue.JS
Javascript MVVM with Vue.JSJavascript MVVM with Vue.JS
Javascript MVVM with Vue.JS
 
Meteor Day Talk
Meteor Day TalkMeteor Day Talk
Meteor Day Talk
 
Beginning MEAN Stack
Beginning MEAN StackBeginning MEAN Stack
Beginning MEAN Stack
 
Full Stack React Workshop [CSSC x GDSC]
Full Stack React Workshop [CSSC x GDSC]Full Stack React Workshop [CSSC x GDSC]
Full Stack React Workshop [CSSC x GDSC]
 
State of modern web technologies: an introduction
State of modern web technologies: an introductionState of modern web technologies: an introduction
State of modern web technologies: an introduction
 
Ta Javaserverside Eran Toch
Ta Javaserverside Eran TochTa Javaserverside Eran Toch
Ta Javaserverside Eran Toch
 
Test Automation for NoSQL Databases
Test Automation for NoSQL DatabasesTest Automation for NoSQL Databases
Test Automation for NoSQL Databases
 
Rest web service_with_spring_hateoas
Rest web service_with_spring_hateoasRest web service_with_spring_hateoas
Rest web service_with_spring_hateoas
 
Node JS Express: Steps to Create Restful Web App
Node JS Express: Steps to Create Restful Web AppNode JS Express: Steps to Create Restful Web App
Node JS Express: Steps to Create Restful Web App
 
AngularJS for Web and Mobile
 AngularJS for Web and Mobile AngularJS for Web and Mobile
AngularJS for Web and Mobile
 
CraftCamp for Students - Introduction to Meteor.js
CraftCamp for Students - Introduction to Meteor.jsCraftCamp for Students - Introduction to Meteor.js
CraftCamp for Students - Introduction to Meteor.js
 
Java Script - A New Look
Java Script - A New LookJava Script - A New Look
Java Script - A New Look
 
How to Build ToDo App with Vue 3 + TypeScript
How to Build ToDo App with Vue 3 + TypeScriptHow to Build ToDo App with Vue 3 + TypeScript
How to Build ToDo App with Vue 3 + TypeScript
 
Practical OData
Practical ODataPractical OData
Practical OData
 
Magento Performance Optimization 101
Magento Performance Optimization 101Magento Performance Optimization 101
Magento Performance Optimization 101
 

Recently uploaded

Story boards and shot lists for my a level piece
Story boards and shot lists for my a level pieceStory boards and shot lists for my a level piece
Story boards and shot lists for my a level piececharlottematthew16
 
"ML in Production",Oleksandr Bagan
"ML in Production",Oleksandr Bagan"ML in Production",Oleksandr Bagan
"ML in Production",Oleksandr BaganFwdays
 
Transcript: New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024
Transcript: New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024Transcript: New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024
Transcript: New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024BookNet Canada
 
CloudStudio User manual (basic edition):
CloudStudio User manual (basic edition):CloudStudio User manual (basic edition):
CloudStudio User manual (basic edition):comworks
 
Leverage Zilliz Serverless - Up to 50X Saving for Your Vector Storage Cost
Leverage Zilliz Serverless - Up to 50X Saving for Your Vector Storage CostLeverage Zilliz Serverless - Up to 50X Saving for Your Vector Storage Cost
Leverage Zilliz Serverless - Up to 50X Saving for Your Vector Storage CostZilliz
 
"Debugging python applications inside k8s environment", Andrii Soldatenko
"Debugging python applications inside k8s environment", Andrii Soldatenko"Debugging python applications inside k8s environment", Andrii Soldatenko
"Debugging python applications inside k8s environment", Andrii SoldatenkoFwdays
 
Advanced Test Driven-Development @ php[tek] 2024
Advanced Test Driven-Development @ php[tek] 2024Advanced Test Driven-Development @ php[tek] 2024
Advanced Test Driven-Development @ php[tek] 2024Scott Keck-Warren
 
SIP trunking in Janus @ Kamailio World 2024
SIP trunking in Janus @ Kamailio World 2024SIP trunking in Janus @ Kamailio World 2024
SIP trunking in Janus @ Kamailio World 2024Lorenzo Miniero
 
What's New in Teams Calling, Meetings and Devices March 2024
What's New in Teams Calling, Meetings and Devices March 2024What's New in Teams Calling, Meetings and Devices March 2024
What's New in Teams Calling, Meetings and Devices March 2024Stephanie Beckett
 
Connect Wave/ connectwave Pitch Deck Presentation
Connect Wave/ connectwave Pitch Deck PresentationConnect Wave/ connectwave Pitch Deck Presentation
Connect Wave/ connectwave Pitch Deck PresentationSlibray Presentation
 
New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024
New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024
New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024BookNet Canada
 
Artificial intelligence in cctv survelliance.pptx
Artificial intelligence in cctv survelliance.pptxArtificial intelligence in cctv survelliance.pptx
Artificial intelligence in cctv survelliance.pptxhariprasad279825
 
"Federated learning: out of reach no matter how close",Oleksandr Lapshyn
"Federated learning: out of reach no matter how close",Oleksandr Lapshyn"Federated learning: out of reach no matter how close",Oleksandr Lapshyn
"Federated learning: out of reach no matter how close",Oleksandr LapshynFwdays
 
Ensuring Technical Readiness For Copilot in Microsoft 365
Ensuring Technical Readiness For Copilot in Microsoft 365Ensuring Technical Readiness For Copilot in Microsoft 365
Ensuring Technical Readiness For Copilot in Microsoft 3652toLead Limited
 
Beyond Boundaries: Leveraging No-Code Solutions for Industry Innovation
Beyond Boundaries: Leveraging No-Code Solutions for Industry InnovationBeyond Boundaries: Leveraging No-Code Solutions for Industry Innovation
Beyond Boundaries: Leveraging No-Code Solutions for Industry InnovationSafe Software
 
DevoxxFR 2024 Reproducible Builds with Apache Maven
DevoxxFR 2024 Reproducible Builds with Apache MavenDevoxxFR 2024 Reproducible Builds with Apache Maven
DevoxxFR 2024 Reproducible Builds with Apache MavenHervé Boutemy
 
Developer Data Modeling Mistakes: From Postgres to NoSQL
Developer Data Modeling Mistakes: From Postgres to NoSQLDeveloper Data Modeling Mistakes: From Postgres to NoSQL
Developer Data Modeling Mistakes: From Postgres to NoSQLScyllaDB
 
Bun (KitWorks Team Study 노별마루 발표 2024.4.22)
Bun (KitWorks Team Study 노별마루 발표 2024.4.22)Bun (KitWorks Team Study 노별마루 발표 2024.4.22)
Bun (KitWorks Team Study 노별마루 발표 2024.4.22)Wonjun Hwang
 
DevEX - reference for building teams, processes, and platforms
DevEX - reference for building teams, processes, and platformsDevEX - reference for building teams, processes, and platforms
DevEX - reference for building teams, processes, and platformsSergiu Bodiu
 
Vertex AI Gemini Prompt Engineering Tips
Vertex AI Gemini Prompt Engineering TipsVertex AI Gemini Prompt Engineering Tips
Vertex AI Gemini Prompt Engineering TipsMiki Katsuragi
 

Recently uploaded (20)

Story boards and shot lists for my a level piece
Story boards and shot lists for my a level pieceStory boards and shot lists for my a level piece
Story boards and shot lists for my a level piece
 
"ML in Production",Oleksandr Bagan
"ML in Production",Oleksandr Bagan"ML in Production",Oleksandr Bagan
"ML in Production",Oleksandr Bagan
 
Transcript: New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024
Transcript: New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024Transcript: New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024
Transcript: New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024
 
CloudStudio User manual (basic edition):
CloudStudio User manual (basic edition):CloudStudio User manual (basic edition):
CloudStudio User manual (basic edition):
 
Leverage Zilliz Serverless - Up to 50X Saving for Your Vector Storage Cost
Leverage Zilliz Serverless - Up to 50X Saving for Your Vector Storage CostLeverage Zilliz Serverless - Up to 50X Saving for Your Vector Storage Cost
Leverage Zilliz Serverless - Up to 50X Saving for Your Vector Storage Cost
 
"Debugging python applications inside k8s environment", Andrii Soldatenko
"Debugging python applications inside k8s environment", Andrii Soldatenko"Debugging python applications inside k8s environment", Andrii Soldatenko
"Debugging python applications inside k8s environment", Andrii Soldatenko
 
Advanced Test Driven-Development @ php[tek] 2024
Advanced Test Driven-Development @ php[tek] 2024Advanced Test Driven-Development @ php[tek] 2024
Advanced Test Driven-Development @ php[tek] 2024
 
SIP trunking in Janus @ Kamailio World 2024
SIP trunking in Janus @ Kamailio World 2024SIP trunking in Janus @ Kamailio World 2024
SIP trunking in Janus @ Kamailio World 2024
 
What's New in Teams Calling, Meetings and Devices March 2024
What's New in Teams Calling, Meetings and Devices March 2024What's New in Teams Calling, Meetings and Devices March 2024
What's New in Teams Calling, Meetings and Devices March 2024
 
Connect Wave/ connectwave Pitch Deck Presentation
Connect Wave/ connectwave Pitch Deck PresentationConnect Wave/ connectwave Pitch Deck Presentation
Connect Wave/ connectwave Pitch Deck Presentation
 
New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024
New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024
New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024
 
Artificial intelligence in cctv survelliance.pptx
Artificial intelligence in cctv survelliance.pptxArtificial intelligence in cctv survelliance.pptx
Artificial intelligence in cctv survelliance.pptx
 
"Federated learning: out of reach no matter how close",Oleksandr Lapshyn
"Federated learning: out of reach no matter how close",Oleksandr Lapshyn"Federated learning: out of reach no matter how close",Oleksandr Lapshyn
"Federated learning: out of reach no matter how close",Oleksandr Lapshyn
 
Ensuring Technical Readiness For Copilot in Microsoft 365
Ensuring Technical Readiness For Copilot in Microsoft 365Ensuring Technical Readiness For Copilot in Microsoft 365
Ensuring Technical Readiness For Copilot in Microsoft 365
 
Beyond Boundaries: Leveraging No-Code Solutions for Industry Innovation
Beyond Boundaries: Leveraging No-Code Solutions for Industry InnovationBeyond Boundaries: Leveraging No-Code Solutions for Industry Innovation
Beyond Boundaries: Leveraging No-Code Solutions for Industry Innovation
 
DevoxxFR 2024 Reproducible Builds with Apache Maven
DevoxxFR 2024 Reproducible Builds with Apache MavenDevoxxFR 2024 Reproducible Builds with Apache Maven
DevoxxFR 2024 Reproducible Builds with Apache Maven
 
Developer Data Modeling Mistakes: From Postgres to NoSQL
Developer Data Modeling Mistakes: From Postgres to NoSQLDeveloper Data Modeling Mistakes: From Postgres to NoSQL
Developer Data Modeling Mistakes: From Postgres to NoSQL
 
Bun (KitWorks Team Study 노별마루 발표 2024.4.22)
Bun (KitWorks Team Study 노별마루 발표 2024.4.22)Bun (KitWorks Team Study 노별마루 발표 2024.4.22)
Bun (KitWorks Team Study 노별마루 발표 2024.4.22)
 
DevEX - reference for building teams, processes, and platforms
DevEX - reference for building teams, processes, and platformsDevEX - reference for building teams, processes, and platforms
DevEX - reference for building teams, processes, and platforms
 
Vertex AI Gemini Prompt Engineering Tips
Vertex AI Gemini Prompt Engineering TipsVertex AI Gemini Prompt Engineering Tips
Vertex AI Gemini Prompt Engineering Tips
 

Simple todo app with meteor

  • 1. TodoAppwith Meteor » Long Nguyen » @vangnol
  • 2. Whatis Meteor? Meteor is a framework for building incredible web application. Meteor helps you build complex web application but in minimal amount of time. It's full- stack framework. On the server it runs on Nodejs, which means Meteor written in Javascript. Meteor has out of the box integration with MongoDB database. Meteor uses DDP Protocal to communicate between client and server.
  • 3. Setup » MacOS or Ubuntu curl https://install.meteor.com/ | sh » Windows Go get a Mac or a Ubuntu laptop
  • 4. Demo Simple Todo App with Meteor ♡♡♡
  • 5. task.html <head> <title>Simple Todo App</title> </head> <body> <h1>Awesome Todo App</h1> <hr/> <div class="container"> {{> CreateTask}} {{> ListTasks}} {{> CompleteCounter}} </div> </body> <template name="ListTasks"> <ul> {{#each tasks}} <li class="task {{doneClass}}">{{> Task}}</li> {{/each}} </ul> </template>
  • 6. <template name="Task"> <input type="checkbox" name="is_done" {{isDoneChecked}} /> {{subject}} </template> <template name="CreateTask"> <form class="create-task" > <input type="text" placeholder="Creating new task...!" /> </form> </template> <template name="CompleteCounter"> <h3>{{completeTask}} / {{totalTasks}} tasks completed</h3> </template>
  • 7. task.css .task{ font-size: 20px; background-color: #EBEBEB; padding: 10px; margin-bottom: 2px; } .done{ text-decoration: line-through; }
  • 8. task.js Todos = new Meteor.Collection('todos'); if(Meteor.isClient){ Template.ListTasks.helpers({ tasks: function(){ return Todos.find(); }, doneClass: function(){ return this.is_done ? 'done' : ''; } }); Template.Task.helpers({ isDoneChecked: function(){ return this.is_done ? 'checked' : '' } });
  • 9. Template.Task.events({ "click [name=is_done]": function(e, tmpl){ var id = this._id; var isDone = tmpl.find('input').checked; Todos.update({_id: id}, {$set: { is_done: isDone}}); } }); Template.CreateTask.events({ 'submit form': function(e, tmpl){ e.preventDefault(); var subject = tmpl.find('input').value; Todos.insert({subject: subject, created_at: new Date, is_done: false}); var form = tmpl.find('form'); form.reset(); } }); }
  • 10. Template.CompleteCounter.helpers({ completeTask: function(){ return Todos.find({is_done: true}).count(); }, totalTasks: function(){ return Todos.find({}).count(); } }); } if(Meteor.isServer){ }
  • 11. References » MeteorHacks » Best Learning Resources » Meteor Packages » Why Meteor will kill Ruby on Rails » Meteor Won’t Kill Rails Anytime Soon » How to Learn JavaScript Properly