Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Init pipeline #3

Merged
merged 2 commits into from
Feb 10, 2024
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
22 changes: 22 additions & 0 deletions .github/workflows/actions.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
name: Pipeline
run-name: Pipeline
on: [push]
jobs:
pipeline:
runs-on: ubuntu-latest
strategy:
matrix:
node-version: [21.x]
steps:
- name: Check out repository code
uses: actions/checkout@v4
- name: Starting Node.js ${{ matrix.node-version}}
uses: actions/setup-node@v3
with:
node-version: ${{ matrix.node-version }}
- name: Install dependencies
run: yarn install
- name: build
run: yarn build
- name: lint
run: yarn lint:ts
2 changes: 1 addition & 1 deletion app/entry.client.tsx
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import { RemixBrowser } from '@remix-run/react'
import { startTransition, StrictMode } from 'react'
import { startTransition } from 'react'
import { hydrateRoot } from 'react-dom/client'
import { Provider } from 'react-redux'
import store from './redux/store'
Expand Down
2 changes: 1 addition & 1 deletion app/routes/courses.$course.tsx
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import { ThunkDispatch } from '@reduxjs/toolkit'
import type { ThunkDispatch } from '@reduxjs/toolkit'
import { useParams } from '@remix-run/react'
import { Spinner } from 'flowbite-react'
import { useEffect, useState } from 'react'
Expand All @@ -20,9 +20,9 @@
formData.append('CourseID', params.course as string)
formData.append('UserID', window.localStorage.getItem("userId") as string)
dispatch(fetchCourse(formData))
}, [])

Check warning on line 23 in app/routes/courses.$course.tsx

View workflow job for this annotation

GitHub Actions / pipeline (21.x)

React Hook useEffect has missing dependencies: 'dispatch' and 'params.course'. Either include them or remove the dependency array

useEffect(() => {

Check warning on line 25 in app/routes/courses.$course.tsx

View workflow job for this annotation

GitHub Actions / pipeline (21.x)

React Hook useEffect contains a call to 'setIsPostLoading'. Without a list of dependencies, this can lead to an infinite chain of updates. To fix this, pass [courses.status] as a second argument to the useEffect Hook
if (courses.status === 'loaded') setIsPostLoading(false)
})

Expand Down
2 changes: 1 addition & 1 deletion app/widgets/helpers/object-to-form-data.ts
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
/* eslint-disable */
export function objectToFormData(obj: any) {
const formData = new FormData();

for (const key in obj) {
// @ts-ignore
if (obj.hasOwnProperty(key)) {
formData.append(key, obj[key]);
}
Expand Down
Loading