Questions tagged [iron-router]

A Meteor smart package for client and server side routing in Meteor.

Iron Router is a routing package for Meteor. It makes single page apps.

IR takes control of your tag, rendering templates based on the user's current URL. It also helps you set up subscriptions per-route and much more.

Iron Router works with Meteor 0.8.0 and above.

More information available here

1663 questions
0
votes
3 answers

what is @params in Iron:router

with meteor's IronRouter, I'm trying to use the this.params object elsewhere, but confused as to what it is. It seems to be a zero length array, that is actually an object with named methods after the path components. # coffee @route 'magnets', …
dcsan
  • 7,487
  • 10
  • 50
  • 80
0
votes
2 answers

Meteor: Iron-router render home page only after successful login

I have the following routes and only wish to perform Router.go('home'); AFTER a successful login. Router.configure({ layoutTemplate: 'Layout'}); Router.map(function(){ this.route('login', {path: '/'}); this.route('home', {path:…
meteorBuzz
  • 2,615
  • 4
  • 26
  • 55
0
votes
1 answer

Do routes in Iron Router run on the client or the server

I have been working with Iron Router, and have been under the impression that the routes run on the server. But recently I was reading through the Accounts-Entry code and noticed that, although the routes are defined in "shared", the methods used…
CodeChimp
  • 7,511
  • 3
  • 35
  • 76
0
votes
0 answers

Meteor: How to show route data on the same url?

There is a collection of Posts. Creating a Link of each post on the home page. Need to show post specific data when a link is clicked. It works fine and show data on new url but don't do anything if Url is given as root /. HomePage.html
Himanshu Yadav
  • 12,533
  • 39
  • 148
  • 273
0
votes
1 answer

IronRouter pathFor - passing parameters from Template helper

I am using IronRouter in my project which has content in different languages. To display message codes I have used UI.registerHelper, as follows: UI.registerHelper('loadMessageCode', function(message) { //Logic in here to load string inside a…
matfin
  • 459
  • 3
  • 14
0
votes
2 answers

Export CSV/XLS from Meteor application

What is the simplest way to export data to CSV from Meteor? How to generate CSV? What I've tried Add Npm package: $ meteor add meteorhacks:npm Add Node.js CSV suite: // packages.json { "csv": "0.4.0", } Add Iron Router package: $ meteor add…
roman
  • 101
  • 3
0
votes
1 answer

Exception in Meteor UI: Error: Illegal HTML attribute name: \

I'm making a Meteor JS app and I keep getting the following error: Exception in Meteor UI: Error: Illegal HTML attribute name: \ at extendAttrs (http://localhost:3000/packages/htmljs.js?a0a9082010d25b3fb44e0f56bdd0a7b4e6bbeb93:322:13) at…
0
votes
3 answers

Iron router: Don't re-render page if wait on changes

I subscribe to a collection using iron router's waitOn functionality. This subscription is dependent on a Session variable.When the Session variable changes, the subscription should be renewed using the new value of the Session variable. This works…
tomet
  • 2,256
  • 3
  • 27
  • 42
0
votes
1 answer

Iron Router: Pass data to client via meteor method

My application uses iron router: When a user hits a certain route that contains a wildcard, I would like to use the value of the wildcard to call a meteor method and have its return value be used to set the data context for the…
tomet
  • 2,256
  • 3
  • 27
  • 42
0
votes
1 answer

Meteor template data context not available in template.created upon refresh

I use the template data context inside a template's created function. Template.temp.created = function() { console.log('this.data'); }; When I go to the page normally--i.e. click the link to the page--I see the console log the correct data object.…
Brian
  • 2,912
  • 2
  • 23
  • 36
0
votes
1 answer

mrt:iron-router-progress in Meteor 0.9.1.1

at first I have to confess that I'm a raw recruit in Meteor. Yesterday I added mrt:iron-router-progress to my meteor project because I wanted to simply add a background picture to myApp. But my Problem is that it doesn't yield into this…
0
votes
2 answers

How to show data from mongoDB with ObjectID

i have an "back end" application which write in MongoDb (in database i have _id: with ObjectId("13f6ea...002")) i use meteor app to show information. Everything was good i displays list of information with {{#each}}. But when i wanted show one…
yan
  • 13
  • 1
  • 4
0
votes
2 answers

What triggers an onAfterAction in IronRouter other than a route change?

I'm having trouble debugging an onAfterAction that I don't want to run. It happens when I click a certain div. Router.go is not being called (verified with debugger; in the iron router code), and the URL is not changing. I can't find anything in my…
Loren
  • 11,184
  • 6
  • 40
  • 67
0
votes
1 answer

iron-router error in meteor.js project, old template's data get re-called

I am developing a meteor.js application, and I am having a strange error. I wrote my code below and as you can see I have a template called groupsmain which shows list of different groups, and when I click one of them, I am going to groupdetail…
user2858924
  • 433
  • 5
  • 15
0
votes
1 answer

One subscription for multiple routes

If I have one subscription that will be used for multiple routes, should I call it each time in every controller's waitOn or is there a better place?
ilyo
  • 33,469
  • 40
  • 99
  • 145
1 2 3
99
100