Is there any Node.js web-framework/app-server like Express, that uses XML as backend, rather than JSON? Or, that can have this plugged in, at least? I'd like to use BaseX (XML document database) as a backend to something like Express.
Show HN: Server.js – A modern Express alternative
91–100 of 124 posts
Re: Show HN: Server.js – A modern Express alternative
#92Earlier quoted context omitted.
IMHO, and one of the reasons I decided to go with server, simplicity is a feature and the advantage of express over Koa. It is hard enough for new users to get started on Node.js, but to have to handle all of the new middleware concepts, PLUS to have to learn a lot more advanced features like generators is a no-go for my framework of choice. - server: return something to reply to the browser. Can use `async` for more…
Koa has been doing async for a while. It's basically connect with promises instead of callbacks: `app.use(async (ctx, next) => { await next(); });`
And `await` is so much easier and safer than callbacks in userland code! Really excited about Node.js in 2018, now that `await` is supported in the LTS release. Callback hell is finally dead.
(Diff showing a refactor of an example app from traditional callbacks to async/await: https://github.com/mikermcneil/chatkin/pull/4/files)
Re: Show HN: Server.js – A modern Express alternative
#93Earlier quoted context omitted.
> I would be so happy if someone took away my power to choose and just forced me to use something that will "just work". You are looking for django/ruby on rails.
No, he and others used to more complete (for lack of a better term) frameworks are looking for the Django/Rails equivalent in Node.js. I got my first taste of Node.js development a few months ago ( https://engineering.edx.org/serverless-984cee7797e1 ) and found it confusing that so much of what I take for granted in Django is kinda all over the place in Node.js. The one that stood out to me was internationalization (…
More likely is that the people who want the features of Django/Rails just use Django/Rails, so there's no goldrush to recreate them in Node nor a monolithic community around the attempts so far.
The Node ecosystem is like the Clojure ecosystem: all-inclusive frameworks just aren't as popular as library composition.
Re: Show HN: Server.js – A modern Express alternative
#94It's very interesting watching node developers re-implement the PHP ecosystem.
Re: Show HN: Server.js – A modern Express alternative
#95Earlier quoted context omitted.
Totally a tangent but, don’t use moment.js! It inherits some of the parsing and other quirks from the awfulness that is the JS Date object, the mutability almost certainly will lead to being bit by a couple of bugs before you actually internalize it, and the time zone support is kind of tacked on as an afterthought. I highly recommend js-joda, particularly if you’ll ever be computing/showing things to your users in d…
For some reason reading the API docs of js-joda gives me flashbacks to Java programming. Maybe it's all the "public static" stuff. Maybe it's that I can't immediately see how to do something useful. Some examples would be nice.
Maybe you'd seen the name somewhere and your subconscious had reminded you, haha
Re: Show HN: Server.js – A modern Express alternative
#96Earlier quoted context omitted.
No, he and others used to more complete (for lack of a better term) frameworks are looking for the Django/Rails equivalent in Node.js. I got my first taste of Node.js development a few months ago ( https://engineering.edx.org/serverless-984cee7797e1 ) and found it confusing that so much of what I take for granted in Django is kinda all over the place in Node.js. The one that stood out to me was internationalization (…
I think you're guilty of the trope that everything should be ported to Node/Javascript. More likely is that the people who want the features of Django/Rails just use Django/Rails, so there's no goldrush to recreate them in Node nor a monolithic community around the attempts so far. The Node ecosystem is like the Clojure ecosystem: all-inclusive frameworks just aren't as popular as library composition.
Express is a nice small framework and is good for some things. Sometimes though you really want a monolith. If you are a Node developer there isn’t a clear choice for this.
I actually enjoy Sails, but I can see some decisions they’ve made that probably aren’t attractive to new developers (such as still using Grunt by default).
Waterline is nice as an ORM on the surface, but you run into walls as your queries become significantly complex.
Re: Show HN: Server.js – A modern Express alternative
#97Rather than changing express's syntax, I would much rather have a better express boilerplate generator with an opinionated stack with good documentation/justification. I recently started learning express/node and wasted weeks googling for blog posts for each dependency to figure out how to configure them. I guess this is somewhat valuable for end-to-end understanding but not for productivity. There are a bunch depend…
> But still a bunch that I haven't gotten to googling and still need to decide on what to choose:
logging (morgan vs winston)
validation (express-validator, joi)
auth (passport jwt, local, social)
session storage (redis vs keeping it in database?)
database (mongo/mongoose vs
pg/knex/bookshelf/sequelize, graphql) storage (s3 vs gcs)
ajax requests (request vs axios)
mail (mailgun, sendgrid, mailchimp)
error handlers
rate limiting
geo ipRe: Show HN: Server.js – A modern Express alternative
#98Earlier quoted context omitted.
For some reason reading the API docs of js-joda gives me flashbacks to Java programming. Maybe it's all the "public static" stuff. Maybe it's that I can't immediately see how to do something useful. Some examples would be nice.
I'm guessing the name is a reference to Joda-Time which is a DateTime library for Java. Maybe you'd seen the name somewhere and your subconscious had reminded you, haha
Re: Show HN: Server.js – A modern Express alternative
#99Earlier quoted context omitted.
Totally a tangent but, don’t use moment.js! It inherits some of the parsing and other quirks from the awfulness that is the JS Date object, the mutability almost certainly will lead to being bit by a couple of bugs before you actually internalize it, and the time zone support is kind of tacked on as an afterthought. I highly recommend js-joda, particularly if you’ll ever be computing/showing things to your users in d…
I've always been of the opinion that timestamps should be stored UTC datetime or unix timestamp on the server side and then displayed to the proper locale by the client's device. Is this not a good method?
Re: Show HN: Server.js – A modern Express alternative
#100Earlier quoted context omitted.
No, he and others used to more complete (for lack of a better term) frameworks are looking for the Django/Rails equivalent in Node.js. I got my first taste of Node.js development a few months ago ( https://engineering.edx.org/serverless-984cee7797e1 ) and found it confusing that so much of what I take for granted in Django is kinda all over the place in Node.js. The one that stood out to me was internationalization (…
I think you're guilty of the trope that everything should be ported to Node/Javascript. More likely is that the people who want the features of Django/Rails just use Django/Rails, so there's no goldrush to recreate them in Node nor a monolithic community around the attempts so far. The Node ecosystem is like the Clojure ecosystem: all-inclusive frameworks just aren't as popular as library composition.