Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 2 additions & 5 deletions .github/workflows/deploy.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,8 +10,5 @@ jobs:
deploy:
uses: Beuterei/reusable-workflows/.github/workflows/deploy-static-app.yml@main
with:
bucket_name: test-static-fes
endpoint: nbg1.your-objectstorage.com
secrets:
ACCESS_KEY: ${{ secrets.AWS_ACCESS_KEY_ID }}
SECRET_KEY: ${{ secrets.AWS_SECRET_ACCESS_KEY }}
project_name: testingsadsdasd
secrets: inherit
13 changes: 10 additions & 3 deletions .github/workflows/qa.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
name: Build and Deploy a static app
name: QA

on:
pull_request:
Expand All @@ -19,13 +19,20 @@ jobs:
linting:
runs-on: ubuntu-latest
needs: setup
permissions:
# Default permissions (matching what would be set if the permissions section was missing at all)
contents: read
packages: read

# Need to add these 2 for eslint-annotate-action
pull-requests: read
checks: write
steps:
- uses: actions/checkout@v4
with:
ref: ${{ github.ref }}
- uses: Beuterei/reusable-workflows/.github/actions/restore-dependency-cache@main
- name:
- name: Linting
uses: Beuterei/reusable-workflows/.github/actions/eslint-runner@main
with:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}

1 change: 1 addition & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@ Currently, two official plugins are available:
- [@vitejs/plugin-react](https://github.com/vitejs/vite-plugin-react/blob/main/packages/plugin-react/README.md) uses [Babel](https://babeljs.io/) for Fast Refresh
- [@vitejs/plugin-react-swc](https://github.com/vitejs/vite-plugin-react-swc) uses [SWC](https://swc.rs/) for Fast Refresh


## Expanding the ESLint configuration

If you are developing a production application, we recommend updating the configuration to enable type aware lint rules:
Expand Down
11 changes: 10 additions & 1 deletion src/App.tsx
Original file line number Diff line number Diff line change
@@ -1,8 +1,10 @@
import { useState } from 'react'
import React, { useState } from 'react'
import reactLogo from './assets/react.svg'
import viteLogo from '/vite.svg'
import './App.css'

export const a = 1

function App() {
const [count, setCount] = useState(0)

Expand Down Expand Up @@ -33,3 +35,10 @@
}

export default App

function ExampleComponent() {

Check failure on line 39 in src/App.tsx

View workflow job for this annotation

GitHub Actions / ESLint Report Analysis

src/App.tsx#L39

[@typescript-eslint/no-unused-vars] 'ExampleComponent' is defined but never used.
if (true) {

Check failure on line 40 in src/App.tsx

View workflow job for this annotation

GitHub Actions / ESLint Report Analysis

src/App.tsx#L40

[no-constant-condition] Unexpected constant condition.
const [state, setState] = React.useState(0); // This breaks the rules of hooks

Check failure on line 41 in src/App.tsx

View workflow job for this annotation

GitHub Actions / ESLint Report Analysis

src/App.tsx#L41

[@typescript-eslint/no-unused-vars] 'state' is assigned a value but never used.

Check failure on line 41 in src/App.tsx

View workflow job for this annotation

GitHub Actions / ESLint Report Analysis

src/App.tsx#L41

[@typescript-eslint/no-unused-vars] 'setState' is assigned a value but never used.

Check failure on line 41 in src/App.tsx

View workflow job for this annotation

GitHub Actions / ESLint Report Analysis

src/App.tsx#L41

[react-hooks/rules-of-hooks] React Hook "React.useState" is called conditionally. React Hooks must be called in the exact same order in every component render.
}
return <div>{state}</div>;
}
Loading