Better way to write list of places program I wrote some code using meteor, which is working, but I don't know if I did it the best way.  I'm asking for opinions on other ways to perform this task.

It's just a list of places.  You can fill the textfield with a place and it'll appear on the list.  You have an option to remove the place by clicking on the "x".

Very simple, but I'm new to meteor.

place_list.js

   Places = new Meteor.Collection('placesNew');
   if(Meteor.isClient){
     Template.places_list.places = function(){
       return Places.find({},{sort:{name: 1}});
      console.log(Template.place_list.place); 
     }

   Template.places_list.events({
     'blur .place': function (obj) {
       Places.insert({name: obj.target.value});
     },
     'click .plc_remove': function(obj){
       Places.remove( obj.toElement.attributes['data-ref'].value);
     }
   });
}


place_list.html

&lt;head&gt;
  &lt;title&gt;Place List&lt;/title&gt;
&lt;/head&gt;
&lt;body&gt;
  &lt;h1&gt;Place List :&lt;/h1&gt;  
  {{&gt; places_list}}
&lt;/body&gt;
&lt;template name="places_list"&gt;
  &lt;input type="text" placeholder="Insert a place here" class="place" /&gt;
  &lt;ul&gt;
  {{#each places}}
     &lt;li&gt; {{ name}} | &lt;a class="plc_remove" data-ref="{{_id}}" href="#"&gt;x&lt;/a&gt; | &lt;/li&gt;
  {{/each}}
  &lt;/ul&gt;
&lt;/template&gt;
Great start! You're very close. I changed things around a little bit, and added an extra template and a separate event map for that template. This should make it easier to understand, and it means you don't have to store the place's id in a data attribute. Check it out:

Places = new Meteor.Collection('places');

if(Meteor.isClient) {
    Template.places_list.places = function () {
        return Places.find({}, { sort: { name: 1 } });
    }

    Template.places_list.events({
        'keypress #place': function (evt) {
            if (evt.which === 13) {
                // The user pressed enter
                Places.insert({ name: evt.currentTarget.value });
                place.currentTarget.value = ''; // Reset the text input
            }
        }
    });

    Template.place_item.events({
        'click .plc_remove': function () {
            Places.remove(this._id); // Access the document fields with this.foo
        }
    });
}


And the HTML:

&lt;head&gt;
    &lt;title&gt;Place List&lt;/title&gt;
&lt;/head&gt;
&lt;body&gt;
    &lt;h1&gt;Place List :&lt;/h1&gt;  
    {{&gt; places_list}}
&lt;/body&gt;

&lt;template name="places_list"&gt;
    &lt;input type="text" placeholder="Insert a place here" id="place" /&gt;

    &lt;ul&gt;
        {{#each places}}
            {{&gt; place_item}}
        {{/each}}
    &lt;/ul&gt;
&lt;/template&gt;

&lt;template name="place_item"&gt;
    &lt;li&gt; {{ name}} | &lt;a class="plc_remove" href="#"&gt;x&lt;/a&gt; | &lt;/li&gt;
&lt;/template&gt;