These are chat archives for michaeljcalkins/developers

28th
Oct 2014
Niall O'Brien
@niallobrien
Oct 28 2014 14:21
Man, that sounds like a lot of work - how's it going so far?
Michael J. Calkins
@michaeljcalkins
Oct 28 2014 14:35
This is actually really fun and much easier than Laravel
Everything is so automatic that generating the api and various nested routes allows me to build it faster
despite the learning curve :P
Niall O'Brien
@niallobrien
Oct 28 2014 14:36
Yeah, the learning curve is steeper alright - also, there's feck all node.js SaaS apps out there it seems
Michael J. Calkins
@michaeljcalkins
Oct 28 2014 14:37
hahaha yes
One thing I just learned this morning was handling errors
My app crashed because a directory didn’t exist and the app was just down.
thats it.
no refresh
just down.
because I didn’t handle an error with something like
if (err) { return handleError(res, err); }
Niall O'Brien
@niallobrien
Oct 28 2014 14:45
So the whole app died?
Michael J. Calkins
@michaeljcalkins
Oct 28 2014 14:46
yeah until I added that line
then it didn’t die anymore
Niall O'Brien
@niallobrien
Oct 28 2014 14:46
And where's handleError coming from?
Michael J. Calkins
@michaeljcalkins
Oct 28 2014 14:47
  fs.writeFile(filepath, new Buffer(response.data, 'base64'), function(err) {
    if (err) { return handleError(res, err); }
Before I didn’t have err in the function()
If you have any heads up on storing temporary files on heroku let me know.
Works locally but not on my web dyno
have you created any apps with afs yet? or anything on heroku?
Niall O'Brien
@niallobrien
Oct 28 2014 14:50
Not yet, still playing with client-side for now.
Michael J. Calkins
@michaeljcalkins
Oct 28 2014 14:52
Are you primarily ruby or php?
Niall O'Brien
@niallobrien
Oct 28 2014 14:52
Php but I do like Rails
Michael J. Calkins
@michaeljcalkins
Oct 28 2014 15:16
Hahah that’s hilarious that you sent mike and i that github link and next thing you know we’re workign with it on gitter ;P
Niall O'Brien
@niallobrien
Oct 28 2014 16:56
Github link?
Michael J. Calkins
@michaeljcalkins
Oct 28 2014 17:00
I meant afs
*
Niall O'Brien
@niallobrien
Oct 28 2014 19:37
so how are you structuring larger apps? I always feel the lack of conventions here are a weakness imo.