So, nginx has examples for routing wildcard subdomains to the same application: http://wiki.nginx.org/ServerBlockExample#Wildcard_Subdomains_in_a_Parent_Folder
After you've done that, you can add a middleware that will examine the subdomain to get the particular user and add it to the request: http://expressjs.com/4x/api.html#req.subdomains
EDIT: Just realized you wanted to add a Ghost blog to each user... That's a bit more complex.
Nice first attempt, looks like you've got some of your external services up and running. My only advice is that in order to be considered somewhat Jarvis like (I'm assuming you're referring to Jarvis from Iron Man), you'll need to get some natural language recognition built in. NLR is really tough to do but you can fake it in a sense using AIML. AIML is an XML like language that chat bots use to give them personality and conversational content. Looks like there is a parser available for node, https://npmjs.org/package/aiml. Good luck!
Oh yeah, nice plug on the xkcd comics ;)
I rarely use Node without Express. It simplifies many tasks, and if you are building a website, I wouldn't go without it. The site explains pretty well how to use it for basic routing, rendering views, database stuff.
npm install express -g express myapp -c stylus -t jade cd myapp && npm install node app.js
Will create a new Express site, using Stylus for styling and Jade for templating. Web development on crack.
have you tried nodeMirror? https://npmjs.org/package/node-mirror it has a handy Editor, a Terminal, Debugger and even a Music Player.
I recently won a Price for giving a Presentation on it. So maybe its worth looking at ;)
It should, but this is synchronous actions we are dealing with and in this case no. Here's a jsfiddle.
Notice line async: true
. If you change it to false, you'll start getting "Ajax call finished" in your console - an indicator that ajax request has finished.
Game Dev Tycoon also uses Node-Webkit (except for the Windows 8 Store app, but they probably share (some?) code with it).
Can confirm that npm on nitrous.io works wonderfully (using it as we speak). Another alternative is Koding, which gives you a full VM.
I agree with some of your points. However, the example which you gave is not correct. You don't need to put the properties in objects. It is only needed if you have two or more nested selectors. I.e. the code above could be transformed to:
body: { width: '100%', marginTop: '20px', header: { width: '200px', p: { fontSize: '20px' } } }
Which produces:
body { width: 100%; margin-top: 20px; } body header { width: 200px; } body header p { font-size: 20px; }
I.e. I don't see where is the problem if (for some reason) width and margin-top have places switched. The problem could occur in the following situation:
body: {
'.bar': {
margin: '2px'
},
'.foo': {
fz: '20px'
},
'.bb': {
fz: '21px'
},
'.aa': {
fz: '22px'
}
}
AbsurdJS (at the moment) compiles the CSS correctly (http://jsbin.com/paqegexe/54/edit) and the selectors are put in the final CSS as they are written in the JavaScript. If there is a problem then the developer should write them in array as you did in your comment.
The power of AbsurdJS (same as the other CSS preprocessors) is the ability to add abstractions. With pure CSS this is not possible. LESS and SASS introduces the mixins which are good example of abstraction. You may combine dozen of things in only one line of code. However, LESS and SASS are somehow limited, because they actually introduce a new syntax. It looks like a CSS, but it is parsed and compiled. They have their own understanding of the input file and their own rules. They are pretty advanced, with great community and support but the problem is that they will never give me the same level of flexibility as JavaScript give me now. I can't have proper inheritance with SASS for example. That's why I wrote AbsurdJS.