Incorporate Auth into all the parts
This commit is contained in:
@@ -49,12 +49,12 @@ token =
|
|||||||
*Note:* Auth.elm is in `.gitignore` to avoid accidentally checking in an API
|
*Note:* Auth.elm is in `.gitignore` to avoid accidentally checking in an API
|
||||||
secret.
|
secret.
|
||||||
|
|
||||||
## Start with Stage 1
|
## Start with Part 1
|
||||||
|
|
||||||
Run this at the terminal:
|
Run this at the terminal:
|
||||||
|
|
||||||
```bash
|
```bash
|
||||||
cd stages/1
|
cd part1
|
||||||
```
|
```
|
||||||
|
|
||||||
Now head over to the [README for stage 1](https://github.com/rtfeldman/elm-workshop/tree/master/stages/1)!
|
Now head over to the [README for Part 1](https://github.com/rtfeldman/elm-workshop/tree/master/part1)!
|
||||||
|
|||||||
@@ -1,14 +0,0 @@
|
|||||||
{
|
|
||||||
"version": "1.0.0",
|
|
||||||
"summary": "helpful summary of your project, less than 80 characters",
|
|
||||||
"repository": "https://github.com/user/project.git",
|
|
||||||
"license": "BSD3",
|
|
||||||
"source-directories": [
|
|
||||||
"."
|
|
||||||
],
|
|
||||||
"exposed-modules": [],
|
|
||||||
"dependencies": {
|
|
||||||
"elm-lang/core": "3.0.0 <= v < 4.0.0"
|
|
||||||
},
|
|
||||||
"elm-version": "0.16.0 <= v < 0.17.0"
|
|
||||||
}
|
|
||||||
@@ -2,6 +2,7 @@ module Main (..) where
|
|||||||
|
|
||||||
import Html exposing (..)
|
import Html exposing (..)
|
||||||
import Html.Attributes exposing (..)
|
import Html.Attributes exposing (..)
|
||||||
|
import Auth
|
||||||
|
|
||||||
|
|
||||||
model =
|
model =
|
||||||
|
|||||||
@@ -4,7 +4,7 @@
|
|||||||
"repository": "https://github.com/rtfeldman/elm-workshop.git",
|
"repository": "https://github.com/rtfeldman/elm-workshop.git",
|
||||||
"license": "BSD-3-Clause",
|
"license": "BSD-3-Clause",
|
||||||
"source-directories": [
|
"source-directories": [
|
||||||
"."
|
".", ".."
|
||||||
],
|
],
|
||||||
"exposed-modules": [],
|
"exposed-modules": [],
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
|
|||||||
@@ -4,6 +4,7 @@ import Html exposing (..)
|
|||||||
import Html.Attributes exposing (..)
|
import Html.Attributes exposing (..)
|
||||||
import Html.Events exposing (..)
|
import Html.Events exposing (..)
|
||||||
import Http
|
import Http
|
||||||
|
import Auth
|
||||||
import Task exposing (Task)
|
import Task exposing (Task)
|
||||||
import Effects exposing (Effects)
|
import Effects exposing (Effects)
|
||||||
import Json.Decode exposing (Decoder, (:=))
|
import Json.Decode exposing (Decoder, (:=))
|
||||||
@@ -18,9 +19,11 @@ searchFeed query =
|
|||||||
let
|
let
|
||||||
-- See https://developer.github.com/v3/search/#example for how to customize!
|
-- See https://developer.github.com/v3/search/#example for how to customize!
|
||||||
url =
|
url =
|
||||||
"https://api.github.com/search/repositories?q="
|
"https://api.github.com/search/repositories?access_token="
|
||||||
|
++ Auth.token
|
||||||
|
++ "&q="
|
||||||
++ query
|
++ query
|
||||||
++ "+language:elm"
|
++ "+language:elm&sort=stars&order=desc"
|
||||||
|
|
||||||
task =
|
task =
|
||||||
Http.get responseDecoder url
|
Http.get responseDecoder url
|
||||||
|
|||||||
@@ -4,7 +4,7 @@
|
|||||||
"repository": "https://github.com/rtfeldman/elm-workshop.git",
|
"repository": "https://github.com/rtfeldman/elm-workshop.git",
|
||||||
"license": "BSD-3-Clause",
|
"license": "BSD-3-Clause",
|
||||||
"source-directories": [
|
"source-directories": [
|
||||||
"."
|
".", ".."
|
||||||
],
|
],
|
||||||
"exposed-modules": [],
|
"exposed-modules": [],
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
|
|||||||
@@ -5,6 +5,7 @@ import Html.Attributes exposing (..)
|
|||||||
import Html.Events exposing (..)
|
import Html.Events exposing (..)
|
||||||
import Html.Lazy exposing (..)
|
import Html.Lazy exposing (..)
|
||||||
import Http
|
import Http
|
||||||
|
import Auth
|
||||||
import Task exposing (Task)
|
import Task exposing (Task)
|
||||||
import Effects exposing (Effects)
|
import Effects exposing (Effects)
|
||||||
import Json.Decode exposing (Decoder, (:=))
|
import Json.Decode exposing (Decoder, (:=))
|
||||||
@@ -19,9 +20,11 @@ searchFeed query =
|
|||||||
let
|
let
|
||||||
-- See https://developer.github.com/v3/search/#example for how to customize!
|
-- See https://developer.github.com/v3/search/#example for how to customize!
|
||||||
url =
|
url =
|
||||||
"https://api.github.com/search/repositories?q="
|
"https://api.github.com/search/repositories?access_token="
|
||||||
|
++ Auth.token
|
||||||
|
++ "&q="
|
||||||
++ query
|
++ query
|
||||||
++ "+language:elm"
|
++ "+language:elm&sort=stars&order=desc"
|
||||||
|
|
||||||
task =
|
task =
|
||||||
Http.get responseDecoder url
|
Http.get responseDecoder url
|
||||||
|
|||||||
@@ -4,7 +4,7 @@
|
|||||||
"repository": "https://github.com/rtfeldman/elm-workshop.git",
|
"repository": "https://github.com/rtfeldman/elm-workshop.git",
|
||||||
"license": "BSD-3-Clause",
|
"license": "BSD-3-Clause",
|
||||||
"source-directories": [
|
"source-directories": [
|
||||||
"."
|
".", ".."
|
||||||
],
|
],
|
||||||
"exposed-modules": [],
|
"exposed-modules": [],
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
|
|||||||
@@ -5,6 +5,7 @@ import Html.Attributes exposing (..)
|
|||||||
import Html.Events exposing (..)
|
import Html.Events exposing (..)
|
||||||
import Html.Lazy exposing (..)
|
import Html.Lazy exposing (..)
|
||||||
import Http
|
import Http
|
||||||
|
import Auth
|
||||||
import Task exposing (Task)
|
import Task exposing (Task)
|
||||||
import Effects exposing (Effects)
|
import Effects exposing (Effects)
|
||||||
import Json.Decode exposing (Decoder, (:=))
|
import Json.Decode exposing (Decoder, (:=))
|
||||||
@@ -18,7 +19,9 @@ searchFeed query =
|
|||||||
let
|
let
|
||||||
-- See https://developer.github.com/v3/search/#example for how to customize!
|
-- See https://developer.github.com/v3/search/#example for how to customize!
|
||||||
url =
|
url =
|
||||||
"https://api.github.com/search/repositories?q="
|
"https://api.github.com/search/repositories?access_token="
|
||||||
|
++ Auth.token
|
||||||
|
++ "&q="
|
||||||
++ query
|
++ query
|
||||||
++ "+language:elm&sort=stars&order=desc"
|
++ "+language:elm&sort=stars&order=desc"
|
||||||
|
|
||||||
|
|||||||
@@ -4,7 +4,7 @@
|
|||||||
"repository": "https://github.com/rtfeldman/elm-workshop.git",
|
"repository": "https://github.com/rtfeldman/elm-workshop.git",
|
||||||
"license": "BSD-3-Clause",
|
"license": "BSD-3-Clause",
|
||||||
"source-directories": [
|
"source-directories": [
|
||||||
"."
|
".", ".."
|
||||||
],
|
],
|
||||||
"exposed-modules": [],
|
"exposed-modules": [],
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
|
|||||||
@@ -2,6 +2,7 @@ module Main (..) where
|
|||||||
|
|
||||||
import Html exposing (..)
|
import Html exposing (..)
|
||||||
import Html.Attributes exposing (..)
|
import Html.Attributes exposing (..)
|
||||||
|
import Auth
|
||||||
|
|
||||||
|
|
||||||
type alias Model =
|
type alias Model =
|
||||||
|
|||||||
@@ -4,7 +4,7 @@
|
|||||||
"repository": "https://github.com/rtfeldman/elm-workshop.git",
|
"repository": "https://github.com/rtfeldman/elm-workshop.git",
|
||||||
"license": "BSD-3-Clause",
|
"license": "BSD-3-Clause",
|
||||||
"source-directories": [
|
"source-directories": [
|
||||||
"."
|
".", ".."
|
||||||
],
|
],
|
||||||
"exposed-modules": [],
|
"exposed-modules": [],
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
|
|||||||
@@ -3,6 +3,7 @@ module Main (..) where
|
|||||||
import Html exposing (..)
|
import Html exposing (..)
|
||||||
import Html.Attributes exposing (..)
|
import Html.Attributes exposing (..)
|
||||||
import Html.Events exposing (..)
|
import Html.Events exposing (..)
|
||||||
|
import Auth
|
||||||
import StartApp.Simple as StartApp
|
import StartApp.Simple as StartApp
|
||||||
import Signal exposing (Address)
|
import Signal exposing (Address)
|
||||||
|
|
||||||
|
|||||||
@@ -4,7 +4,7 @@
|
|||||||
"repository": "https://github.com/rtfeldman/elm-workshop.git",
|
"repository": "https://github.com/rtfeldman/elm-workshop.git",
|
||||||
"license": "BSD-3-Clause",
|
"license": "BSD-3-Clause",
|
||||||
"source-directories": [
|
"source-directories": [
|
||||||
"."
|
".", ".."
|
||||||
],
|
],
|
||||||
"exposed-modules": [],
|
"exposed-modules": [],
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
|
|||||||
@@ -3,6 +3,7 @@ module Main (..) where
|
|||||||
import Html exposing (..)
|
import Html exposing (..)
|
||||||
import Html.Attributes exposing (..)
|
import Html.Attributes exposing (..)
|
||||||
import Html.Events exposing (..)
|
import Html.Events exposing (..)
|
||||||
|
import Auth
|
||||||
import StartApp.Simple as StartApp
|
import StartApp.Simple as StartApp
|
||||||
import Json.Encode
|
import Json.Encode
|
||||||
import Signal exposing (Address)
|
import Signal exposing (Address)
|
||||||
|
|||||||
@@ -4,7 +4,7 @@
|
|||||||
"repository": "https://github.com/rtfeldman/elm-workshop.git",
|
"repository": "https://github.com/rtfeldman/elm-workshop.git",
|
||||||
"license": "BSD-3-Clause",
|
"license": "BSD-3-Clause",
|
||||||
"source-directories": [
|
"source-directories": [
|
||||||
"."
|
".", ".."
|
||||||
],
|
],
|
||||||
"exposed-modules": [],
|
"exposed-modules": [],
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
|
|||||||
@@ -3,6 +3,7 @@ module Main (..) where
|
|||||||
import Html exposing (..)
|
import Html exposing (..)
|
||||||
import Html.Attributes exposing (..)
|
import Html.Attributes exposing (..)
|
||||||
import Html.Events exposing (..)
|
import Html.Events exposing (..)
|
||||||
|
import Auth
|
||||||
import StartApp
|
import StartApp
|
||||||
import Http
|
import Http
|
||||||
import Task exposing (Task)
|
import Task exposing (Task)
|
||||||
@@ -37,7 +38,9 @@ searchFeed query =
|
|||||||
let
|
let
|
||||||
-- See https://developer.github.com/v3/search/#example for how to customize!
|
-- See https://developer.github.com/v3/search/#example for how to customize!
|
||||||
url =
|
url =
|
||||||
"https://api.github.com/search/repositories?q="
|
"https://api.github.com/search/repositories?access_token="
|
||||||
|
++ Auth.token
|
||||||
|
++ "&q="
|
||||||
++ query
|
++ query
|
||||||
++ "+language:elm&sort=stars&order=desc"
|
++ "+language:elm&sort=stars&order=desc"
|
||||||
in
|
in
|
||||||
|
|||||||
@@ -4,7 +4,7 @@
|
|||||||
"repository": "https://github.com/rtfeldman/elm-workshop.git",
|
"repository": "https://github.com/rtfeldman/elm-workshop.git",
|
||||||
"license": "BSD-3-Clause",
|
"license": "BSD-3-Clause",
|
||||||
"source-directories": [
|
"source-directories": [
|
||||||
"."
|
".", ".."
|
||||||
],
|
],
|
||||||
"exposed-modules": [],
|
"exposed-modules": [],
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
|
|||||||
@@ -4,6 +4,7 @@ import Html exposing (..)
|
|||||||
import Html.Attributes exposing (..)
|
import Html.Attributes exposing (..)
|
||||||
import Html.Events exposing (..)
|
import Html.Events exposing (..)
|
||||||
import Http
|
import Http
|
||||||
|
import Auth
|
||||||
import Task exposing (Task)
|
import Task exposing (Task)
|
||||||
import Effects exposing (Effects)
|
import Effects exposing (Effects)
|
||||||
import Json.Decode exposing (Decoder, (:=))
|
import Json.Decode exposing (Decoder, (:=))
|
||||||
@@ -16,7 +17,9 @@ searchFeed address query =
|
|||||||
let
|
let
|
||||||
-- See https://developer.github.com/v3/search/#example for how to customize!
|
-- See https://developer.github.com/v3/search/#example for how to customize!
|
||||||
url =
|
url =
|
||||||
"https://api.github.com/search/repositories?q="
|
"https://api.github.com/search/repositories?access_token="
|
||||||
|
++ Auth.token
|
||||||
|
++ "&q="
|
||||||
++ query
|
++ query
|
||||||
++ "+language:elm&sort=stars&order=desc"
|
++ "+language:elm&sort=stars&order=desc"
|
||||||
|
|
||||||
|
|||||||
@@ -4,7 +4,7 @@
|
|||||||
"repository": "https://github.com/rtfeldman/elm-workshop.git",
|
"repository": "https://github.com/rtfeldman/elm-workshop.git",
|
||||||
"license": "BSD-3-Clause",
|
"license": "BSD-3-Clause",
|
||||||
"source-directories": [
|
"source-directories": [
|
||||||
"."
|
".", ".."
|
||||||
],
|
],
|
||||||
"exposed-modules": [],
|
"exposed-modules": [],
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
|
|||||||
@@ -4,6 +4,7 @@ import Html exposing (..)
|
|||||||
import Html.Attributes exposing (..)
|
import Html.Attributes exposing (..)
|
||||||
import Html.Events exposing (..)
|
import Html.Events exposing (..)
|
||||||
import Http
|
import Http
|
||||||
|
import Auth
|
||||||
import Task exposing (Task)
|
import Task exposing (Task)
|
||||||
import Effects exposing (Effects)
|
import Effects exposing (Effects)
|
||||||
import Json.Decode exposing (Decoder, (:=))
|
import Json.Decode exposing (Decoder, (:=))
|
||||||
@@ -17,9 +18,11 @@ searchFeed query =
|
|||||||
let
|
let
|
||||||
-- See https://developer.github.com/v3/search/#example for how to customize!
|
-- See https://developer.github.com/v3/search/#example for how to customize!
|
||||||
url =
|
url =
|
||||||
"https://api.github.com/search/repositories?q="
|
"https://api.github.com/search/repositories?access_token="
|
||||||
|
++ Auth.token
|
||||||
|
++ "&q="
|
||||||
++ query
|
++ query
|
||||||
++ "+language:elm"
|
++ "+language:elm&sort=stars&order=desc"
|
||||||
|
|
||||||
task =
|
task =
|
||||||
Http.get responseDecoder url
|
Http.get responseDecoder url
|
||||||
|
|||||||
@@ -4,7 +4,7 @@
|
|||||||
"repository": "https://github.com/rtfeldman/elm-workshop.git",
|
"repository": "https://github.com/rtfeldman/elm-workshop.git",
|
||||||
"license": "BSD-3-Clause",
|
"license": "BSD-3-Clause",
|
||||||
"source-directories": [
|
"source-directories": [
|
||||||
"."
|
".", ".."
|
||||||
],
|
],
|
||||||
"exposed-modules": [],
|
"exposed-modules": [],
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
|
|||||||
@@ -5,6 +5,7 @@ import Html.Attributes exposing (..)
|
|||||||
import Html.Events exposing (..)
|
import Html.Events exposing (..)
|
||||||
import Html.Lazy exposing (..)
|
import Html.Lazy exposing (..)
|
||||||
import Http
|
import Http
|
||||||
|
import Auth
|
||||||
import Task exposing (Task)
|
import Task exposing (Task)
|
||||||
import Effects exposing (Effects)
|
import Effects exposing (Effects)
|
||||||
import Json.Decode exposing (Decoder, (:=))
|
import Json.Decode exposing (Decoder, (:=))
|
||||||
@@ -19,9 +20,11 @@ searchFeed query =
|
|||||||
let
|
let
|
||||||
-- See https://developer.github.com/v3/search/#example for how to customize!
|
-- See https://developer.github.com/v3/search/#example for how to customize!
|
||||||
url =
|
url =
|
||||||
"https://api.github.com/search/repositories?q="
|
"https://api.github.com/search/repositories?access_token="
|
||||||
|
++ Auth.token
|
||||||
|
++ "&q="
|
||||||
++ query
|
++ query
|
||||||
++ "+language:elm"
|
++ "+language:elm&sort=stars&order=desc"
|
||||||
|
|
||||||
task =
|
task =
|
||||||
Http.get responseDecoder url
|
Http.get responseDecoder url
|
||||||
|
|||||||
@@ -4,7 +4,7 @@
|
|||||||
"repository": "https://github.com/rtfeldman/elm-workshop.git",
|
"repository": "https://github.com/rtfeldman/elm-workshop.git",
|
||||||
"license": "BSD-3-Clause",
|
"license": "BSD-3-Clause",
|
||||||
"source-directories": [
|
"source-directories": [
|
||||||
"."
|
".", ".."
|
||||||
],
|
],
|
||||||
"exposed-modules": [],
|
"exposed-modules": [],
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
|
|||||||
Reference in New Issue
Block a user