Skip to content

Commit

Permalink
fix: all paths now support being deployed in a subdirectory like /sta…
Browse files Browse the repository at this point in the history
…ging/
  • Loading branch information
activescott committed Dec 25, 2020
1 parent 1f4914a commit eab2a1c
Show file tree
Hide file tree
Showing 17 changed files with 5,627 additions and 1,098 deletions.
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@ src/lib/**/*.js
.arc-env
sam.json
sam.yaml
/coverage/
# react-app compiled assets (these are regengerated by re-building src/react-app/
/public/
!/public/readme.md
Expand Down
6 changes: 6 additions & 0 deletions .vscode/settings.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
{
"cSpell.words": [
"cookieconsent",
"csrf"
]
}
9 changes: 8 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -70,10 +70,17 @@ arc env staging FOO myvalue

- Allow adding multiple OAuth Authorization servers to allow a user to authenticate:

- [ ] feat: configuration for client ID & secret
- [ ] feat(authentication): configuration for client ID & secret for google
- [ ] CSRF tokens to protect against login attacks: https://cheatsheetseries.owasp.org/cheatsheets/Cross-Site_Request_Forgery_Prevention_Cheat_Sheet.html#synchronizer-token-pattern
- [ ] feat: DDB tables to store user and table to store tokens by provider
- [ ] feat: user can use one or more OAuth providers

- [ ] feat: CSRF token middleware in all state-changing APIs:

- [ ] CSRF server support: automatic detection/rejection
- [ ] CSRF client support: Automatic inclusion of the token

- [ ] feat: bundle static assets (js, css, images) instead of using PUBLIC_URL as described at https://create-react-app.dev/docs/using-the-public-folder/#when-to-use-the-public-folder
- [ ] chore: basic unit tests
- [ ] chore: git hooks for linting
- [ ] chore: git hooks for unit tests
Expand Down
1 change: 1 addition & 0 deletions app.arc
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@ post /api/echo

@aws
region us-west-2
profile web_app_stack

@static
folder public
12 changes: 12 additions & 0 deletions jest.config.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
module.exports = {
preset: "ts-jest",
testEnvironment: "node",
setupFiles: ["./test/support/setup.ts"],
globals: {
"ts-jest": {
tsconfig: "tsconfig.json",
},
},
collectCoverageFrom: ["src/**/*.ts", "!src/react-app/**"],
testPathIgnorePatterns: ["/node_modules/", "/src/react-app/"],
}

0 comments on commit eab2a1c

Please sign in to comment.