Olá Julio obrigado pela dica mas, apos alterar a branch o front-end não abre no meu browser e aparece os erros abaixo. Já com a main tudo é visualizável porem não funcional.
Compiled with problems:X
ERROR in ./src/http/index.ts 3:0-26
Module not found: Error: Can't resolve 'axios' in 'C:\Users\rhuan\OneDrive\Area de trabalho\Cursos Alura\Curso HTTP\curso-react-alurabooks\src\http'
ERROR in ./src/http/index.ts 3:0-26
Module not found: Error: Can't resolve 'axios' in 'C:\Users\rhuan\OneDrive\Area de trabalho\Cursos Alura\Curso HTTP\curso-react-alurabooks\src\http'
ERROR in src/componentes/ModalLoginUsuario/index.tsx:27:19
TS7006: Parameter 'reposta' implicitly has an 'any' type.
25 | }
26 | http.post('public/login', usuario)
27 | .then(reposta => {
| ^^^^^^^
28 | sessionStorage.setItem('token', reposta.data.access_token)
29 | setEmail('')
30 | setSenha('')
ERROR in src/componentes/ModalLoginUsuario/index.tsx:33:20
TS7006: Parameter 'erro' implicitly has an 'any' type.
31 | aoEfetuarLogin()
32 | })
33 | .catch(erro => {
| ^^^^
34 | if (erro?.response?.data?.message) {
35 | alert(erro.response.data.message)
36 | } else {
ERROR in src/http/index.ts:1:19
TS2307: Cannot find module 'axios' or its corresponding type declarations.
1 | import axios from "axios";
| ^^^^^^^
2 |
3 | const http = axios.create({
4 | baseURL: 'http://localhost:8000',
ERROR in src/http/index.ts:11:41
TS7006: Parameter 'config' implicitly has an 'any' type.
9 | })
10 |
11 | http.interceptors.request.use(function (config) {
| ^^^^^^
12 | // Do something before request is sent
13 | const token = sessionStorage.getItem('token')
14 | if (token && config.headers) {
ERROR in src/http/index.ts:18:16
TS7006: Parameter 'error' implicitly has an 'any' type.
16 | }
17 | return config;
18 | }, function (error) {
| ^^^^^
19 | // Do something with request error
20 | console.log('Erro no interceptor do axios')
21 | return Promise.reject(error);
ERROR in src/paginas/Pedidos/index.tsx:15:19
TS7006: Parameter 'resposta' implicitly has an 'any' type.
13 | useEffect(() => {
14 | http.get<IPedido[]>('pedidos')
15 | .then(resposta => setPedidos(resposta.data))
| ^^^^^^^^
16 | .catch(erro => console.log(erro))
17 | }, [])
18 |
ERROR in src/paginas/Pedidos/index.tsx:16:20
TS7006: Parameter 'erro' implicitly has an 'any' type.
14 | http.get<IPedido[]>('pedidos')
15 | .then(resposta => setPedidos(resposta.data))
16 | .catch(erro => console.log(erro))
| ^^^^
17 | }, [])
18 |
19 | return (