Skip to content

Commit 2fa0ece

Browse files
authored
Merge pull request #3 from function-and-mountain/chore/add-1week_practice
chore: Add 1week practices in 테오 & 파랑 studies
2 parents 3b1a9a7 + ee96eb4 commit 2fa0ece

File tree

192 files changed

+9521
-4795
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

192 files changed

+9521
-4795
lines changed

.eslintrc.json

+25-21
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,6 @@
66
"airbnb",
77
"plugin:import/errors",
88
"plugin:import/warnings",
9-
"plugin:prettier/recommended",
109
"plugin:@typescript-eslint/recommended",
1110
"plugin:@next/next/recommended"
1211
],
@@ -21,23 +20,28 @@
2120
"rules": {
2221
"quote-props": "warn",
2322
"@typescript-eslint/consistent-type-imports": "error",
24-
"@typescript-eslint/no-empty-function": 0,
25-
"react/button-has-type": 0,
26-
"jsx-a11y/media-has-caption": 0,
27-
"import/prefer-default-export": 0, // 0 -> 0ff / 1 -> on (default)
28-
"prettier/prettier": 0,
29-
"no-alert": 0,
30-
"import/extensions": 0,
31-
"consistent-return": 1,
32-
"no-use-before-define": 0,
33-
"import/no-unresolved": 0,
34-
"import/no-extraneous-dependencies": 0, // 테스트 또는 개발환경을 구성하는 파일에서는 devDependency 사용을 허용
35-
"no-shadow": 0,
36-
"react/prop-types": 0,
23+
"@typescript-eslint/no-empty-function": "off",
24+
"react/button-has-type": "off",
25+
"jsx-a11y/media-has-caption": "off",
26+
"import/prefer-default-export": "off", // 0 -> 0ff / 1 -> warn (default)
27+
"no-alert": "off",
28+
"object-curly-newline": "off",
29+
"import/extensions": "off",
30+
"react/jsx-one-expression-per-line": "off",
31+
"consistent-return": "warn",
32+
"no-use-before-define": "off",
33+
"import/no-unresolved": "off",
34+
"import/no-extraneous-dependencies": "off", // 테스트 또는 개발환경을 구성하는 파일에서는 devDependency 사용을 허용
35+
"no-shadow": "off",
36+
"react/prop-types": "off",
3737
"react/require-default-props": "off",
38-
"react/react-in-jsx-scope": 0,
39-
"react/jsx-props-no-spreading": 0,
40-
"react/jsx-filename-extension": [2, { "extensions": [".js", ".jsx", ".ts", ".tsx"] }],
38+
"react/react-in-jsx-scope": "off",
39+
"react/jsx-props-no-spreading": "off",
40+
"semi": "off",
41+
"react/jsx-filename-extension": [
42+
2,
43+
{ "extensions": [".js", ".jsx", ".ts", ".tsx"] }
44+
],
4145
// redux-toolkit docs https://redux-toolkit.js.org/usage/immer-reducers#linting-state-mutations
4246
"no-param-reassign": [
4347
"error",
@@ -53,9 +57,9 @@
5357
"argsIgnorePattern": "^_"
5458
}
5559
],
56-
"react/function-component-definition": 0,
57-
"react/destructuring-assignment": 0,
58-
"@typescript-eslint/prefer-namespace-keyword": 0,
60+
"react/function-component-definition": "off",
61+
"react/destructuring-assignment": "off",
62+
"@typescript-eslint/prefer-namespace-keyword": "off",
5963
"jsx-a11y/anchor-is-valid": [
6064
// nextjs 에서 a tag 에 href 를 기대하는 이슈로 인해
6165
"error",
@@ -65,7 +69,7 @@
6569
"aspects": ["invalidHref", "preferButton"]
6670
}
6771
],
68-
"no-underscore-dangle": 0,
72+
"no-underscore-dangle": "off",
6973
"react-hooks/rules-of-hooks": "error",
7074
"react-hooks/exhaustive-deps": "error",
7175
"react/no-unknown-property": ["error", { "ignore": ["css"] }]

.pnp.cjs

+7,159-4,569
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

.prettierrc

+4-2
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,8 @@
11
{
22
"arrowParens": "always",
3-
"printWidth": 100,
3+
"printWidth": 80,
44
"quoteProps": "preserve",
5-
"trailingComma": "all"
5+
"trailingComma": "all",
6+
"semi": false,
7+
"singleQuote": true
68
}

.vscode/settings.json

+3-1
Original file line numberDiff line numberDiff line change
@@ -5,5 +5,7 @@
55
},
66
"eslint.nodePath": ".yarn/sdks",
77
"typescript.tsdk": ".yarn/sdks/typescript/lib",
8-
"typescript.enablePromptUseWorkspaceTsdk": true
8+
"typescript.enablePromptUseWorkspaceTsdk": true,
9+
"jestrunner.enableYarnPnpSupport": true,
10+
"jestrunner.yarnPnpCommand": "yarn-3.6.1.cjs"
911
}
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.

.yarn/sdks/prettier/index.js

+20
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,20 @@
1+
#!/usr/bin/env node
2+
3+
const {existsSync} = require(`fs`);
4+
const {createRequire} = require(`module`);
5+
const {resolve} = require(`path`);
6+
7+
const relPnpApiPath = "../../../.pnp.cjs";
8+
9+
const absPnpApiPath = resolve(__dirname, relPnpApiPath);
10+
const absRequire = createRequire(absPnpApiPath);
11+
12+
if (existsSync(absPnpApiPath)) {
13+
if (!process.versions.pnp) {
14+
// Setup the environment to be able to require prettier
15+
require(absPnpApiPath).setup();
16+
}
17+
}
18+
19+
// Defer to the real prettier your application uses
20+
module.exports = absRequire(`prettier`);

.yarn/sdks/prettier/package.json

+6
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
{
2+
"name": "prettier",
3+
"version": "3.0.0-sdk",
4+
"main": "./index.js",
5+
"type": "commonjs"
6+
}
+47-46
Original file line numberDiff line numberDiff line change
@@ -1,48 +1,49 @@
1-
import { Box, Flex, Image, Text } from "@chakra-ui/react";
2-
import { AvatarProps } from "./Avatar.types";
1+
import { Box, Flex, Image, Text } from '@chakra-ui/react'
2+
import type { AvatarProps } from './Avatar.types'
33

4-
export const Avatar = ({ ghId, username, name }: AvatarProps) => {
5-
return (
6-
<Flex
7-
flexDir="column"
8-
alignItems="center"
9-
display="inline-flex"
10-
gap="10px"
11-
_hover={{
12-
".go-to-wrapper": {
13-
visibility: "visible",
14-
fontSize: "20px",
15-
},
16-
}}
17-
>
18-
<Box position="relative" overflow="hidden" borderRadius="50%">
19-
<Image src={`https://avatars.githubusercontent.com/u/${ghId}?v=4`} w="173px" />
20-
<Text
21-
className="go-to-wrapper"
22-
position="absolute"
23-
top="0"
24-
right="0"
25-
bottom="0"
26-
left="0"
27-
as="a"
28-
href={`https://github.com/${username}`}
29-
target="_blank"
30-
visibility="hidden"
31-
backgroundColor="black"
32-
display="flex"
33-
alignItems="center"
34-
justifyContent="center"
35-
fontSize="16px"
36-
color="#009972"
37-
transition="font-size 0.3s ease-out"
38-
>
39-
Go to Github
40-
</Text>
41-
</Box>
42-
43-
<Text>
44-
{name} / {username}
4+
export const Avatar = ({ ghId, username, name }: AvatarProps) => (
5+
<Flex
6+
flexDir="column"
7+
alignItems="center"
8+
display="inline-flex"
9+
gap="10px"
10+
_hover={{
11+
'.go-to-wrapper': {
12+
visibility: 'visible',
13+
fontSize: '20px',
14+
},
15+
}}
16+
>
17+
<Box position="relative" overflow="hidden" borderRadius="50%">
18+
<Image
19+
src={`https://avatars.githubusercontent.com/u/${ghId}?v=4`}
20+
w="173px"
21+
/>
22+
<Text
23+
className="go-to-wrapper"
24+
position="absolute"
25+
top="0"
26+
right="0"
27+
bottom="0"
28+
left="0"
29+
as="a"
30+
href={`https://github.com/${username}`}
31+
target="_blank"
32+
visibility="hidden"
33+
backgroundColor="black"
34+
display="flex"
35+
alignItems="center"
36+
justifyContent="center"
37+
fontSize="16px"
38+
color="#009972"
39+
transition="font-size 0.3s ease-out"
40+
>
41+
Go to Github
4542
</Text>
46-
</Flex>
47-
);
48-
};
43+
</Box>
44+
45+
<Text>
46+
{name} / {username}
47+
</Text>
48+
</Flex>
49+
)

apps/docs/components/Avatar/index.ts

+1-1
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
export { Avatar } from "./Avatar";
1+
export { Avatar } from './Avatar'

apps/docs/components/icons/File.tsx

+16-18
Original file line numberDiff line numberDiff line change
@@ -1,18 +1,16 @@
1-
export const File = () => {
2-
return (
3-
<svg
4-
xmlns="http://www.w3.org/2000/svg"
5-
fill="none"
6-
viewBox="0 0 24 24"
7-
strokeWidth={1.5}
8-
stroke="currentColor"
9-
className="h-6 w-6"
10-
>
11-
<path
12-
strokeLinecap="round"
13-
strokeLinejoin="round"
14-
d="M15.75 17.25v3.375c0 .621-.504 1.125-1.125 1.125h-9.75a1.125 1.125 0 01-1.125-1.125V7.875c0-.621.504-1.125 1.125-1.125H6.75a9.06 9.06 0 011.5.124m7.5 10.376h3.375c.621 0 1.125-.504 1.125-1.125V11.25c0-4.46-3.243-8.161-7.5-8.876a9.06 9.06 0 00-1.5-.124H9.375c-.621 0-1.125.504-1.125 1.125v3.5m7.5 10.375H9.375a1.125 1.125 0 01-1.125-1.125v-9.25m12 6.625v-1.875a3.375 3.375 0 00-3.375-3.375h-1.5a1.125 1.125 0 01-1.125-1.125v-1.5a3.375 3.375 0 00-3.375-3.375H9.75"
15-
/>
16-
</svg>
17-
);
18-
};
1+
export const File = () => (
2+
<svg
3+
xmlns="http://www.w3.org/2000/svg"
4+
fill="none"
5+
viewBox="0 0 24 24"
6+
strokeWidth={1.5}
7+
stroke="currentColor"
8+
className="h-6 w-6"
9+
>
10+
<path
11+
strokeLinecap="round"
12+
strokeLinejoin="round"
13+
d="M15.75 17.25v3.375c0 .621-.504 1.125-1.125 1.125h-9.75a1.125 1.125 0 01-1.125-1.125V7.875c0-.621.504-1.125 1.125-1.125H6.75a9.06 9.06 0 011.5.124m7.5 10.376h3.375c.621 0 1.125-.504 1.125-1.125V11.25c0-4.46-3.243-8.161-7.5-8.876a9.06 9.06 0 00-1.5-.124H9.375c-.621 0-1.125.504-1.125 1.125v3.5m7.5 10.375H9.375a1.125 1.125 0 01-1.125-1.125v-9.25m12 6.625v-1.875a3.375 3.375 0 00-3.375-3.375h-1.5a1.125 1.125 0 01-1.125-1.125v-1.5a3.375 3.375 0 00-3.375-3.375H9.75"
14+
/>
15+
</svg>
16+
)

apps/docs/components/icons/index.ts

+1-1
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
export { File } from "./File";
1+
export { File } from './File'

apps/docs/components/index.ts

+2-2
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,2 @@
1-
export { Avatar } from "./Avatar";
2-
export * from "./icons";
1+
export { Avatar } from './Avatar'
2+
export * from './icons'

apps/docs/package.json

+2-2
Original file line numberDiff line numberDiff line change
@@ -24,9 +24,9 @@
2424
},
2525
"devDependencies": {
2626
"@nutshell/ts-config": "workspace:^",
27-
"eslint": "8.43.0",
27+
"eslint": "*",
2828
"next-compose-plugins": "^2.2.1",
2929
"supports-color": "^9.4.0",
30-
"typescript": "5.1.3"
30+
"typescript": "*"
3131
}
3232
}

apps/docs/pages/_app.tsx

+3-3
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
1-
import type { AppProps } from "next/app";
2-
import "./reset.css";
1+
import type { AppProps } from 'next/app'
2+
import './reset.css'
33

44
export default function App({ Component, pageProps }: AppProps) {
5-
return <Component {...pageProps} />;
5+
return <Component {...pageProps} />
66
}

apps/docs/pages/_document.tsx

+13-15
Original file line numberDiff line numberDiff line change
@@ -1,17 +1,15 @@
1-
import { Head, Html, Main, NextScript } from "next/document";
1+
import { Head, Html, Main, NextScript } from 'next/document'
22

3-
const Document = () => {
4-
return (
5-
<Html>
6-
<Head>
7-
<link rel="shortcut icon" href="/favicon.ico" />
8-
</Head>
3+
const Document = () => (
4+
<Html>
5+
<Head>
6+
<link rel="shortcut icon" href="/favicon.ico" />
7+
</Head>
98

10-
<body>
11-
<Main />
12-
<NextScript />
13-
</body>
14-
</Html>
15-
);
16-
};
17-
export default Document;
9+
<body>
10+
<Main />
11+
<NextScript />
12+
</body>
13+
</Html>
14+
)
15+
export default Document

apps/docs/theme.config.jsx

+16-17
Original file line numberDiff line numberDiff line change
@@ -2,32 +2,31 @@
22
export default {
33
logo: <span>쏙쏙쑥쑥</span>,
44
project: {
5-
link: "https://github.com/function-and-mountain/functional-coding-nutshell",
5+
link: 'https://github.com/function-and-mountain/functional-coding-nutshell',
66
},
77
docsRepositoryBase:
8-
"https://github.com/function-and-mountain/functional-coding-nutshell/tree/main/apps/docs",
8+
'https://github.com/function-and-mountain/functional-coding-nutshell/tree/main/apps/docs',
99
sidebar: {
1010
toggleButton: true,
1111
},
1212
useNextSeoProps() {
1313
return {
14-
titleTemplate: "%s – 쏙쏙쑥쑥",
14+
titleTemplate: '%s – 쏙쏙쑥쑥',
1515
};
1616
},
1717
footer: {
18-
text: () => {
19-
return (
20-
<div style={{ display: "flex", flexDirection: "column" }}>
21-
<span>© 함수랑 산악회</span>
22-
<a
23-
style={{ color: "#009972", textDecoration: "underline" }}
24-
href="https://open.kakao.com/o/sTjHAUsf"
25-
target="_blank"
26-
>
27-
<span>Contact Us</span>
28-
</a>
29-
</div>
30-
);
31-
},
18+
text: () => (
19+
<div style={{ display: 'flex', flexDirection: 'column' }}>
20+
<span>© 함수랑 산악회</span>
21+
<a
22+
style={{ color: '#009972', textDecoration: 'underline' }}
23+
href="https://open.kakao.com/o/sTjHAUsf"
24+
target="_blank"
25+
rel="noreferrer"
26+
>
27+
<span>Contact Us</span>
28+
</a>
29+
</div>
30+
),
3231
},
3332
};

jest.config.js

+11
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
/** @type {import('ts-jest').JestConfigWithTsJest} */
2+
module.exports = {
3+
rootDir: "./",
4+
preset: "ts-jest",
5+
transform: {
6+
"^.+\\.(ts|tsx)?$": "ts-jest",
7+
},
8+
moduleFileExtensions: ["js", "ts"],
9+
testEnvironment: "node",
10+
projects: ["<rootDir>/packages/*/jest.config.js"],
11+
};

0 commit comments

Comments
 (0)