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

[Fix] 메인이미지 경로 변경 #116

Merged
merged 4 commits into from
Nov 21, 2023
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
6 changes: 5 additions & 1 deletion app/frontend/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,11 @@
<html lang="en">
<head>
<meta charset="UTF-8" />
<link rel="icon" type="image/svg+xml" href="src/assets/icons/morak.ico" />
<link
rel="icon"
type="image/svg+xml"
href="public/assets/icons/morak.ico"
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

얘는 public/morak.ico에 관리하자는 말이었습니다! 사실 사용하는 icon이라고 볼 수는 없으니까요

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

해당 경로로 파일을 옮기고 적용해봤는데, npm run dev에서는 파비콘이 보이지 않고 npm run buildpreview를 하면 파비콘이 보이네요? 이유는 잘 모르겠습니다...

/>
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<link rel="preconnect" href="https://fonts.googleapis.com" />
<link rel="preconnect" href="https://fonts.gstatic.com" crossorigin />
Expand Down
1 change: 0 additions & 1 deletion app/frontend/public/vite.svg

This file was deleted.

1 change: 0 additions & 1 deletion app/frontend/src/assets/react.svg

This file was deleted.

2 changes: 1 addition & 1 deletion app/frontend/src/constants/Main.ts
Original file line number Diff line number Diff line change
@@ -1 +1 @@
export const MAIN_IMAGE = '/src/assets/images/main.png';
export const MAIN_IMAGE = 'assets/images/main.png';
8 changes: 7 additions & 1 deletion app/frontend/vite.config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,13 @@ import path from 'path';
export default defineConfig({
plugins: [react(), vanillaExtractPlugin(), svgr()],
resolve: {
alias: [{ find: '@', replacement: path.resolve(__dirname, 'src') }],
alias: [
{
find: '@/assets',
replacement: path.resolve(__dirname, 'public/assets'),
},
{ find: '@', replacement: path.resolve(__dirname, 'src') },
],
extensions: ['.js', '.ts', '.jsx', '.tsx', '.css', '.css.ts'],
},
});
Loading