meteor

How do I modify spark.js? I'm getting the following error: Exception from Deps recompute: TypeError: Cannot read property 'nodeName' of null

爷,独闯天下 提交于 2020-01-14 04:28:08
问题 UPDATE: The problem is NOT in spark - Although I misunderstood what was going on, and thus the question is somewhat poorly formed, I am leaving this question up just in case it benefits others. I'm getting the following error: Exception from Deps recompute: TypeError: Cannot read property 'nodeName' of null at Patcher.match (http://localhost:3000/packages/spark.js?3a050592ceb34d6c585c70f1df11e353610be0ab:1540:12) When I click on the link at the second line, it directs me to the following

meteor collection fetching too slow

烈酒焚心 提交于 2020-01-14 03:28:07
问题 I have an app that subscribes to 4 collections (the collections are very small 1 to 20 records each). But the amount of time it takes to load these collections is huge. One of them is just 13 records, and it takes several seconds to load its template. Is it normal? (I'm still testing on meteor servers) this is a sample of the code : Meteor.subscribe('trackedUser', function() { console.log('finished fetching trackedUser'); Template.users.rendered = function() { /*handlign of the template*/

Meteor Google Maps Autocomplete only works once on multiple templates

可紊 提交于 2020-01-14 03:23:05
问题 I am using a Google Places autocomplete package with Meteor and if I have the user select a location in one template, the autocomplete won't work again in a different template. For instance, if the user picks an autocomplete location for an event they are hosting, and then they try to set their profile location in the profile settings, no autocomplete locations pop up. In fact, if they even activate the autocomplete dropdown on one page (without even selecting one of the options), it won't

Meteor.js and Mongoose Compatibility

走远了吗. 提交于 2020-01-13 20:46:09
问题 I want to use the Mongoose ORM with meteor mainly on the server side until meteor releases a schema approach. Can i call Mongoose ORM operations within Meteor methods and publish using the Mongoose retrieving methods like findById . Are there any potential problems or meteor features that i would miss out on if i approached things this way? 回答1: Unfortunately, there are problems. We've wanted to do the same thing, but (out of the box) the mongoose package doesn't use Meteor's DDP protocol,

MeteorJS email form validation

ε祈祈猫儿з 提交于 2020-01-13 19:32:27
问题 Total novice here. I'm trying to do a client side form validation for a subscribe to newsletter form. My client side code is such. Template.body.events({ "submit .new-subscriber": function (event) { // This function is called when the new task form is submitted var newEmail = event.target.newEmail.value; if (newEmail is email?){ Meteor.call("addNewSubscriber", newEmail); } I'm not sure how to perform form validation here? Can I perform the same server side? 回答1: We currently use two different

Meteor Heroku App Crash after deployment

房东的猫 提交于 2020-01-13 09:59:53
问题 After deploying the app to heroku, my app fails to start. I think this might be to do with the build pack and latest version of meteor 0.9.x? Where should I start to debug this from? 2014-09-02T05:02:58.848513+00:00 heroku[web.1]: State changed from crashed to starting 2014-09-02T05:03:05.407436+00:00 heroku[web.1]: Starting process with command `.meteor/heroku_build/bin/node .meteor/heroku_build/app/main.js` 2014-09-02T05:03:06.578829+00:00 app[web.1]: module.js:340 2014-09-02T05:03:06

how to properly configure meteor to work with node file uploading module 'multer'

╄→гoц情女王★ 提交于 2020-01-13 08:11:27
问题 I'm just starting with meteor. I've found, and added the 'multer' package: meteor add pfafman:multer Now, I wonder how to configure the server side of meteor to use. In my plain node app, I use it like this: app.use(multer({ dest: './uploads/', rename: function (fieldname, filename) { return filename+Date.now(); }, onFileUploadStart: function (file) { console.log(file.originalname + ' is starting ...'); }, onFileUploadComplete: function (file) { console.log(file.fieldname + ' uploaded to ' +

Meteor: Unexpected mongo exit code 14. Restarting.Can't start mongo server

☆樱花仙子☆ 提交于 2020-01-13 07:42:30
问题 when i try to start meteor app i get this error => Started proxy. Unexpected mongo exit code 14. Restarting. Unexpected mongo exit code 14. Restarting. and i when try to access mongodb via shell everything is ok and shell opens and connects to mongodb mongodb log file is also clean and doesn't show any error i'm running mongo with my os is Ubuntu 16.04 mongod --fork --logpath /var/log/mongodb.log 回答1: Try: meteor update --release *LAST STABLE VERSION FOR YOU* meteor If it's still not working,

declare global namespace variable from TypeScript

痞子三分冷 提交于 2020-01-13 07:39:21
问题 How to explicitly declare a variable in the global namespace from typescript? I need the compiler to generate the following javascript code: MyExtension = someFunction() unfortunately, I can only have it generate var MyExtension = someFunction() This comes to an issue with the latest version (still in rc) of meteor packages. Meteor introduced a way to scope namespaces in packages - the issue is, the variable needs to be defined in the global namespace (which meteor reroutes to its own Package

Meteor collection query 'undefined'

无人久伴 提交于 2020-01-13 06:42:08
问题 I have the code datas = new Meteor.Collection("datas") var data = datas.findOne('101abcde1f2345ac00000001') if (Meteor.is_client) { Meteor.startup(function () { console.log(data.name) }); } But what I get in the console is an undefined error. However if I type console.log(data.name) into the web inspector's javascript console (presumably after some kind of wait it works. I'm already putting the code in Meteor.startup to ensure that the DOM is ready. what could I be doing wrong? 回答1: It seems