Skip to content

Instantly share code, notes, and snippets.

<head>
<title>Todo List</title>
</head>
<body>
<div class="container">
<header>
<h1>Todo List</h1>
<form class="new-task">
Tasks = new Mongo.Collection("tasks");
if (Meteor.isClient) {
// This code only runs on the client
Template.body.helpers({
tasks: function () {
// Show newest tasks first
return Tasks.find({}, {sort: {createdAt: -1}});
}
});
<head>
<title>Todo List</title>
</head>
<body>
<div class="container">
<header>
<h1>Todo List</h1>
<form class="new-task">
Tasks = new Mongo.Collection("tasks");
if (Meteor.isClient) {
// This code only runs on the client
Template.body.helpers({
tasks: function () {
return Tasks.find({});
}
});
}
<head>
<title>Todo List</title>
</head>
<body>
<div class="container">
<header>
<h1>Todo List</h1>
</header>
gem 'webpay', '~> 3.1' # WebPay
@shu0115
shu0115 / file0.txt
Last active August 29, 2015 14:09
Meteor Getting Started & Tutorial ref: http://qiita.com/shu_0115/items/ba73c979cd8cf8152219
curl https://install.meteor.com/ | sh
----------
% Total % Received % Xferd Average Speed Time Time Time Current
Dload Upload Total Spent Left Speed
100 6117 0 6117 0 0 2958 0 --:--:-- 0:00:02 --:--:-- 2959
Downloading Meteor distribution
######################################################################## 100.0%
Meteor 1.0 has been installed in your home directory (~/.meteor).
Writing a launcher script to /usr/local/bin/meteor for your convenience.
@shu0115
shu0115 / file0.txt
Last active August 29, 2015 14:09
Herokuステージング環境作成 ref: http://qiita.com/shu_0115/items/0378fd8de049a9b7d77b
heroku fork -a APPNAME APPNAME-staging
@shu0115
shu0115 / file0.txt
Created October 22, 2014 04:45
Mac OS X 10.9.4(Mavericks) + Ruby 2.1.3 + Rails 4.1.6 + Heroku Toolbeltセットアップ ref: http://qiita.com/shu_0115/items/72305bff6a1318769e0a
ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)"
----------
==> This script will install:
/usr/local/bin/brew
/usr/local/Library/...
/usr/local/share/man/man1/brew.1
Press RETURN to continue or any other key to abort
==> /usr/bin/sudo /bin/mkdir /usr/local
@shu0115
shu0115 / file0.txt
Created July 9, 2014 08:34
to_hashメソッドを追加するだけのGem作成 ref: http://qiita.com/shu_0115/items/db4656401fde7881283d
ruby -v
----------
ruby 2.1.1p76 (2014-02-24 revision 45161) [x86_64-darwin12.0]
----------