angular-app / Samples

Sample code - chapter by chapter

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Including libraries

petebacondarwin opened this issue · comments

Should we refer to specific local libraries, such as ../lib/angular/angular.js or refer to online version, such as http://code.angularjs.org/1.0.5/angular.js

The benefit of the first approach is that we can change what version we run off without having to go and change all the index.html files. The downside is that it makes it a bit of a pain if we have to distribute each chapter as a single zip file that will need to contain a copy of the libraries.

I'm preparing for rewrites and was wondering about the same... Not sure what is the best curse of actions here....

OK, so it turns out that some of my code examples already relay on 1.1.x features. I've commented out some tests for now but if we want to demonstrate some of 1.1.x features (http request interceptors, for example) we will need to do a big jump.

BUT as of now it is all a bit of a mess... Some samples reference AngularJS from the CDN, some other from the lib folder. In both cases we've got hard-coded version number so bumping it is not fun.

I was thinking of the best solution and I would say that we should keep AngularJS in the lib folder so we can easily update it. On top of this it would allow running examples without inet connection. This is all fine but kind of kills idea of plunkers...

For now I'm would probably vote for putting it in the lib folder without a version number.

+1
Alternatively use bower install angular-unstable?

... sent from my tablet
On Jun 1, 2013 7:04 PM, "Pawel Kozlowski" notifications@github.com wrote:

OK, so it turns out that some of my code examples already relay on 1.1.x
features. I've commented out some tests for now but if we want to
demonstrate some of 1.1.x features (http request interceptors, for example)
we will need to do a big jump.

BUT as of now it is all a bit of a mess... Some samples reference
AngularJS from the CDN, some other from the lib folder. In both cases we've
got hard-coded version number so bumping it is not fun.

I was thinking of the best solution and I would say that we should keep
AngularJS in the lib folder so we can easily update it. On top of this it
would allow running examples without inet connection. This is all fine but
kind of kills idea of plunkers...

For now I'm would probably vote for putting it in the lib folder without
a version number.


Reply to this email directly or view it on GitHubhttps://github.com//issues/6#issuecomment-18793952
.