mauricemach / zappa

Node development for the lazy.
zappajs.org
MIT License
950 stars 85 forks source link

require('jquery') #9

Closed dvv closed 13 years ago

dvv commented 13 years ago

Hi! I have 'window is not defined', 'navigator is not defined' and so on at zappa.coffee L7. How do you manage to require('jquery')? Is it github.com/jquery/jquery?

--Vladimir

mauricemach commented 13 years ago

Hi Vladimir,

No, it's the npm package announced here. It's just a neater packaging of jsdom + jQuery.

When you installed the latest zappa npm should have installed the jquery package as well. When you type npm ls jquery, do you see it?

dvv commented 13 years ago

Oh, I see. Then we may close the issue. I don't use npm since I want the code completely reside under the project root dir. I use kriszyp's nodules to fetch the deps.

BTW, I think for zappa to be a complete framework it should have decent DB support (presumably providing RESTful JSON interface), web user administration and asset management. Modern web sites rarely end up being just html page servers. I'm exploring that at https://github.com/dvv/farm project

Best regards, --Vladimir

mauricemach commented 13 years ago

Sorry to assume that! And if there's anything I can do to ease installation with nodules, please let me know.

The DB thing I'm trying not to get into since it's not simple to get right, there are already good projects out there, and I still need to work a lot on CK and zappa to make them rock-solid. I do plan though on providing excellent integration with one or more "nORM" libs. On my projects I'm using mongoose currently, it's the best, but it was not intended to take advantage of CoffeeScript. I think something like naturalethic's Congo is the way to go for zappa. Ideally also it shouldn't be tied to MongoDB, I think we need something like ruby's datamapper, data-source agnostic.

Asset management is spot on the money though. I'll keep a close look on farm, depending on how it evolves we could integrate the two, or absorb some features in zappa.

Thanks for the ideas Vladimir, keep 'em coming!

dvv commented 13 years ago

Well, npm appears to be of mainstream and as I discovered (after talk to isaac) that it is able to keep cloned git repos as its packages (to ease developer's life) I'm ok with npm.