Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
students
butter-studio
Commits
13fc7bb7
Commit
13fc7bb7
authored
Jul 14, 2021
by
Kim, Subin
Browse files
TMDBUrl 추가
parent
61b30624
Changes
2
Hide whitespace changes
Inline
Side-by-side
client/src/components/BoxOffice/BoxOffice.js
View file @
13fc7bb7
import
axios
from
"
axios
"
import
axios
from
"
axios
"
import
baseUrl
from
'
../../utils/baseUrl
'
import
{
baseUrl
}
from
'
../../utils/baseUrl
'
import
React
,
{
useState
,
useEffect
}
from
"
react
"
import
React
,
{
useState
,
useEffect
}
from
"
react
"
import
styles
from
"
./box-office.module.scss
"
import
styles
from
"
./box-office.module.scss
"
const
BoxOffice
=
()
=>
{
const
BoxOffice
=
()
=>
{
...
@@ -28,16 +28,16 @@ const BoxOffice = () => {
...
@@ -28,16 +28,16 @@ const BoxOffice = () => {
const
response
=
await
axios
.
get
(
`
${
baseUrl
}
/api/movie`
)
const
response
=
await
axios
.
get
(
`
${
baseUrl
}
/api/movie`
)
console
.
log
(
response
.
data
)
console
.
log
(
response
.
data
)
}
catch
(
error
)
{
}
catch
(
error
)
{
}
}
}
}
async
function
name
()
{
async
function
name
()
{
}
}
return
(
return
(
<
div
className
=
"
container
"
>
<
div
className
=
"
container
"
>
<
h2
className
=
"
fw-bold text-white text-center mt-5
"
>
Box
Office
<
/h2
>
<
h2
className
=
"
fw-bold text-white text-center mt-5
"
>
Box
Office
<
/h2
>
<
div
id
=
"
multi-carousel
"
className
=
{
`d-flex carousel slide align-items-center
${
styles
.
customHeight
}
`
}
data
-
bs
-
ride
=
"
carousel
"
>
<
div
id
=
"
multi-carousel
"
className
=
{
`d-flex carousel slide align-items-center
${
styles
.
customHeight
}
`
}
data
-
bs
-
ride
=
"
carousel
"
>
...
...
client/src/utils/baseUrl.js
View file @
13fc7bb7
...
@@ -4,4 +4,6 @@ const baseUrl = process.env.NODE_ENV === 'production'
...
@@ -4,4 +4,6 @@ const baseUrl = process.env.NODE_ENV === 'production'
?
`http://localhost:3001/
${
clientConfig
.
serverRoot
}
`
?
`http://localhost:3001/
${
clientConfig
.
serverRoot
}
`
:
`http://localhost:3000`
:
`http://localhost:3000`
export
default
baseUrl
const
TMDBUrl
=
"
https://api.themoviedb.org/3/movie
"
\ No newline at end of file
export
{
baseUrl
,
TMDBUrl
}
\ No newline at end of file
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment