Using angularjs without NodeJS (and bower)

5,313 views
Skip to first unread message

Rein Petersen

unread,
Jan 7, 2014, 10:46:58 AM1/7/14
to ang...@googlegroups.com
Hi All,

I want to use AngularJS without using NodeJS. All the examples I have seen seem to depend on NodeJS presumably to include bower to manage packages.

I don't really want to run NodeJS and prefer just a plain old webserver which I feel should be sufficient. Obviously I won't be using Bower which requires javascript to run on the server (via NodeJS).

Is there any suggestions or documents I should read on the subject? I haven't found much doing my own searches.

Thanks, 
Rein

Mauro Servienti

unread,
Jan 7, 2014, 10:56:00 AM1/7/14
to ang...@googlegroups.com
There should be any problem at all, I sing angular in a project backed by asp.net webapi without using nodejs nor bower. Are you facing any specific problem?

.m


--
You received this message because you are subscribed to the Google Groups "AngularJS" group.
To unsubscribe from this group and stop receiving emails from it, send an email to angular+u...@googlegroups.com.
To post to this group, send email to ang...@googlegroups.com.
Visit this group at http://groups.google.com/group/angular.
For more options, visit https://groups.google.com/groups/opt_out.

Joseph Curtin

unread,
Jan 7, 2014, 10:58:37 AM1/7/14
to ang...@googlegroups.com

Rein, read up on REST and HTTP.
http://en.m.wikipedia.org/wiki/Representational_state_transfer

http://en.m.wikipedia.org/wiki/Hypertext_Transfer_Protocol

Try to understand were the client meets the server.

Then use something like
$ python -m SimpleHTTPServer 0.0.0.0:3000
To server static files.

Cheers,
-Joseph Curtin

--

Michael Bielski

unread,
Jan 7, 2014, 11:01:30 AM1/7/14
to ang...@googlegroups.com
My team used Angular without Node or Bower for almost a year and a half with no problems. You simply put the Angular files in a folder and reference them in your main page. This being said, in December we switched to Yeoman and have been enjoying it quite a bit. We still have control over what updates we get, and our build/testing process are now managed very effectively. Do you have a specific reason for your aversion to Node?

Rein Petersen

unread,
Jan 7, 2014, 11:13:42 AM1/7/14
to ang...@googlegroups.com
Thanks for the responses.

I have REST services covered with Firebase. My only aversion to NodeJS is the extra complication and requirement of dedicated ip - otherwise a javascript server seems very appealing to me. Because Im using Firebase I don't really require NodeJS for REST services. Also, Im planning to use phonegap and I will likely run the files from the client locally (not served from a webserver). While I could still use NodeJS to have bower manage the packages it seems like overkill... unless the package management is a very complicated mess as the app grows...

Why is bower important when using AngularJS? Is it really that complicated to manage an angularjs application?

Rein

Rein Petersen

unread,
Jan 7, 2014, 11:13:45 AM1/7/14
to ang...@googlegroups.com
Thanks for the responses.

I have REST services covered with Firebase. My only aversion to NodeJS is the extra complication and requirement of dedicated ip - otherwise a javascript server seems very appealing to me. Because Im using Firebase I don't really require NodeJS for REST services. Also, Im planning to use phonegap and I will likely run the files from the client locally (not served from a webserver). While I could still use NodeJS to have bower manage the packages it seems like overkill... unless the package management is a very complicated mess as the app grows...

Why is bower important when using AngularJS? Is it really that complicated to manage an angularjs application?

Rein

On Tuesday, January 7, 2014 11:01:30 AM UTC-5, Michael Bielski wrote:

phil pastorek

unread,
Jan 7, 2014, 11:35:08 AM1/7/14
to ang...@googlegroups.com
Bower isn't required either to use angular. Bower is a package manager to keep any dependencies you might use in your project up to date or the ability via configuration to specify versions of the dependencies. You are completely free of course to download your dependencies manually and include them on your index.html as you would expect.

Michael Bielski

unread,
Jan 7, 2014, 11:36:54 AM1/7/14
to ang...@googlegroups.com
Ah... I see now...

My team doesn't use Node for any of our REST services (our app runs from Apache.) Wanting to run your app in Phonegap is fine, but do you really want to send uncompressed code out in your app? That eats up bandwidth and in general makes for a larger package to deliver. 

Is it that complicated to manage an Angular application? No. You can update Angular yourself, along with any other external add-ins to it. You'll spend time checking for updates, downloading them, and then copying them into your project. Bower does that for you with a simple command that runs many times faster than you can type, read, download, and copy. No, it's not overkill. It is simplicity at its best. As an example, we upgraded our Angular version to 1.2.7 yesterday. Each member of the team typed "bower install" into a terminal window (command prompt) in WebStorm and then went back to whatever else they were doing. When the command finished, they closed the terminal window. The update was applied immediately to the code we were developing and was able to be posted to the server for testing via our normal development processes. When we ran the next build, the same updated version was included automatically.

Seriously, make your life easier by switching to Yeoman. Having one or two-word commands to enter (or better yet, be able to bind them to a custom button in WebStorm) that make tons of things happen in the right sequence and result in a fully tested and compressed package frees up blocks of time that you can spend developing your app instead of managing it. Yes, I sound like a commercial, but I do believe in the product and highly recommend it.

phil pastorek

unread,
Jan 7, 2014, 11:39:07 AM1/7/14
to ang...@googlegroups.com
+10

Sander Elias

unread,
Jan 7, 2014, 1:45:40 PM1/7/14
to ang...@googlegroups.com
Hi Rein,

You don't need node or bower, or anything else then angular. <- That's a really big period!
You don't even need a local copy of angular for that matter, just include it from an cdn and you are good to go.
It is very easy to manage an angular app. Just include what you need, and you are good to go.

However, if you want to test your application you need some tools to run the tests. those tools rely on node. If you want to test (and you really should!!) you need NodeJS.  Not because you need it for your app, but the test-suite is running on top of it.

If your application is going to be bigger, you probably want to do some minimizing/optimizing. For this part there are lot of tools, and tool runners. most of those also need NodeJS. 

Regards
Sander

Simona Avornicesei

unread,
Jan 7, 2014, 3:07:48 PM1/7/14
to ang...@googlegroups.com
Of course NodeJS and bower are not needed for development but how about testing? Unit and e2e testing, since much of the logic moves from server to client side ....

António Ramos

unread,
Jan 7, 2014, 4:43:57 PM1/7/14
to ang...@googlegroups.com
I´m using deployd.com persistence API

Its very simple and fast and .. you know what i mean.

:)



2014/1/7 Simona Avornicesei <savorn...@gmail.com>
Of course NodeJS and bower are not needed for development but how about testing? Unit and e2e testing, since much of the logic moves from server to client side ....

--
Reply all
Reply to author
Forward
0 new messages