Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import React, { useState, useCallback, useEffect } from "react"; | |
import { usePlaidLink } from "react-plaid-link"; | |
import axios from "axios"; | |
import qs from "qs"; | |
const tokenURL = `http://localhost:8000/api/create_link_token`; | |
const sendTokenURL = `http://localhost:8000/api/set_access_token`; | |
const Link = () => { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
server { | |
listen 80; | |
location / { | |
root /usr/share/nginx/html; | |
index index.html index.htm; | |
try_files $uri $uri/ /index.html; | |
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# STAGE 1 - build the react app | |
# set the base image to build from | |
# This is the application image from which all other subsequent | |
# applications run. Alpine Linux is a security-oriented, lightweight #(~5Mb) Linux distribution. | |
FROM node:alpine as build | |
# set working directory | |
# this is the working folder in the container from which the app. # will be running from | |
WORKDIR /app | |
# add the node_modules folder to $PATH | |
ENV PATH /app/node_modules/.bin:$PATH |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
version: "3.8" | |
services: | |
go: | |
env_file: | |
- .env | |
build: | |
context: . | |
dockerfile: ./go/Dockerfile | |
ports: ["8000:8000"] |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
func main() { | |
r := gin.Default() | |
r.POST("/api/info", info) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
func main() { | |
r := gin.Default() | |
mainPage := "../html/index.html" | |
oauthPage := "../html/oauth-response.html" | |
r.LoadHTMLFiles(mainPage, oauthPage) | |
r.Static("/static", "../static") | |
r.POST("/api/info", info) | |
r.GET("/", func(c *gin.Context) { | |
c.HTML(http.StatusOK, "index.html", gin.H{}) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var ( | |
// set constants from env | |
PLAID_CLIENT_ID = os.Getenv("PLAID_CLIENT_ID") | |
PLAID_SECRET = os.Getenv("PLAID_SECRET") | |
PLAID_ENV = os.Getenv("PLAID_ENV") | |
PLAID_PRODUCTS = os.Getenv("PLAID_PRODUCTS") | |
PLAID_COUNTRY_CODES = os.Getenv("PLAID_COUNTRY_CODES") | |
PLAID_REDIRECT_URI = os.Getenv("PLAID_REDIRECT_URI") | |
APP_PORT = os.Getenv("APP_PORT") | |
) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var ( | |
PLAID_CLIENT_ID = "" | |
PLAID_SECRET = "" | |
PLAID_ENV = "" | |
PLAID_PRODUCTS = "" | |
PLAID_COUNTRY_CODES = "" | |
PLAID_REDIRECT_URI = "" | |
APP_PORT = "" | |
client *plaid.Client = nil | |
) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Get your Plaid API keys from the dashboard: https://dashboard.plaid.com/account/keys | |
PLAID_CLIENT_ID=CLIENT ID | |
PLAID_SECRET=SANDBOX SECRET | |
# Use 'sandbox' to test with fake credentials in Plaid's Sandbox environment | |
# Use 'development' to test with real credentials while developing | |
# Use 'production' to go live with real users | |
PLAID_ENV=sandbox | |
# PLAID_PRODUCTS is a comma-separated list of products to use when | |
# initializing Link, e.g. PLAID_PRODUCTS=auth,transactions. | |
# see https://plaid.com/docs/api/tokens/#create-a-link_token for a complete list |
NewerOlder