ソースを参照

Separating front-end dependencies between AngularJS client and Django Hackathon Starter

David Leonard 10 年 前
コミット
2b6e5f8442
3 ファイル変更37 行追加5 行削除
  1. 14 2
      README.md
  2. 1 3
      bower.json
  3. 22 0
      public/bower.json

+ 14 - 2
README.md

@@ -29,11 +29,23 @@ First, install `bower`:
     npm install -g bower
 
 Then:
-
+    # In the same directory as requirements.txt
     bower install
 
 This will download and extract all the packages listed within `bower.json`. **Under no circumstance should any front-end libraries manually be pushed up to the repository.**
 
+Then:
+    # move bower_components into static folder
+    mv bower_components/ hackathon_starter/hackathon/static
+
+To install the front-end dependencies for the AngularJS client, do the following:
+
+    cd public
+    bower install
+    # Rename bower_components folder to vendor
+    mv bower_components/ vendor/
+
+
 ## Testing
 
 This project aims to be as close to 100% tested as possible. For a good guide to testing using Python and `Mock`, `Nosetests` and `Unittests` libraries, please [read here](http://docs.python-guide.org/en/latest/writing/tests/).
@@ -44,7 +56,7 @@ To run the tests:
 
 ## Code evaluation
 
-In order to write clean code with a consistent style guide, we'll be using `Pylint` to maintain our code. Pylint will display a ton of messages regarding things that should be fixed. A sample output from running `pylint views.py` is shown below:
+In order to write clean code with a consistent style guide, we'll be using `Pylint` to maintain our code. Pylint will display a ton of messages regarding things that should be fixed. 
 
 
 ## RESTful endpoints

+ 1 - 3
bower.json

@@ -15,8 +15,6 @@
   "dependencies": {
     "bootstrap": "~3.3.4",
     "jquery": "~2.1.3",
-    "bootstrap-social": "~4",
-    "angular": "~1.3.15",
-    "angular-ui-router": "~0.2.13"
+    "bootstrap-social": "~4"
   }
 }

+ 22 - 0
public/bower.json

@@ -0,0 +1,22 @@
+{
+  "name": "django-hackathon-starter",
+  "version": "0.0.0",
+  "authors": [
+    "David Leonard <sephirothcloud1025@yahoo.com>"
+  ],
+  "description": "Django boilerplate project for hackathons",
+  "keywords": [
+    "Django",
+    "Python",
+    "API",
+    "RESTful"
+  ],
+  "license": "MIT",
+  "dependencies": {
+    "bootstrap": "~3.3.4",
+    "jquery": "~2.1.3",
+    "bootstrap-social": "~4",
+    "angular": "~1.3.15",
+    "angular-ui-router": "~0.2.13"
+  }
+}