& R
## Usage
### Default
-```tsx
+```tsx title="typescript"
import { LazyImage } from '@modern-kit/react';
import img1 from '../assets/img1.png';
import img2 from '../assets/img2.png';
@@ -44,7 +47,7 @@ const Example = () => {
### Fallback
-```tsx
+```tsx title="typescript"
import { LazyImage } from '@modern-kit/react';
import img1 from '../assets/img1.png';
@@ -69,7 +72,7 @@ const Example = () => {
width: '400px',
height: '400px',
backgroundColor: '#cdcbcb',
- }
+ };
return (
@@ -84,7 +87,7 @@ const Example = () => {
/>
);
-};
+};
```
## Example
diff --git a/docs/docs/react/components/Portal.mdx b/docs/docs/react/components/Portal.mdx
index cd56113a1..151a9e706 100644
--- a/docs/docs/react/components/Portal.mdx
+++ b/docs/docs/react/components/Portal.mdx
@@ -12,8 +12,11 @@ Portal 컴포넌트는 `Modal`, `Dialog`, `Tooltip`과 같은 기능과 함께
+## Code
+[🔗 실제 구현 코드 확인](https://github.com/modern-agile-team/modern-kit/blob/main/packages/react/src/components/Portal/index.tsx)
+
## Interface
-```tsx
+```ts title="typescript"
function Portal({
children,
containerRef,
@@ -26,7 +29,7 @@ function Portal({
## Usage
### Default
-```tsx
+```tsx title="typescript"
import { Portal } from '@modern-kit/react'
const Example = () => {
@@ -40,7 +43,7 @@ const Example = () => {
### Container
-```tsx
+```tsx title="typescript"
import { Portal } from '@modern-kit/react'
const Example = () => {
@@ -60,7 +63,7 @@ const Example = () => {
### Nested
-```tsx
+```tsx title="typescript"
import { Portal } from '@modern-kit/react'
const Example = () => {
diff --git a/docs/docs/react/components/SwithCase.mdx b/docs/docs/react/components/SwithCase.mdx
index 0cc22ba6a..7c2d3ecd7 100644
--- a/docs/docs/react/components/SwithCase.mdx
+++ b/docs/docs/react/components/SwithCase.mdx
@@ -11,8 +11,11 @@ import { SwitchCase } from '@modern-kit/react';
+## Code
+[🔗 실제 구현 코드 확인](https://github.com/modern-agile-team/modern-kit/blob/main/packages/react/src/components/SwitchCase/index.tsx)
+
## Interface
-```tsx
+```ts title="typescript"
type Component = Nullable;
interface SwitchCaseProps {
@@ -29,8 +32,7 @@ const SwitchCase: ({
```
## Usage
-
-```tsx
+```tsx title="typescript"
import { SwitchCase } from '@modern-kit/react';
diff --git a/docs/docs/react/components/When.mdx b/docs/docs/react/components/When.mdx
index 644d80623..5633622ae 100644
--- a/docs/docs/react/components/When.mdx
+++ b/docs/docs/react/components/When.mdx
@@ -9,8 +9,11 @@ condition prop으로 `boolean을 반환하는 함수`도 허용됩니다.
+## Code
+[🔗 실제 구현 코드 확인](https://github.com/modern-agile-team/modern-kit/blob/main/packages/react/src/components/When/index.tsx)
+
## Interface
-```tsx
+```ts title="typescript"
type Condition = boolean | (() => boolean);
interface WhenProps {
@@ -26,8 +29,7 @@ const When: ({
```
## Usage
-
-```tsx
+```tsx title="typescript"
import { When } from '@modern-kit/react';
const Example = () => {
diff --git a/docs/docs/react/hooks/useAsyncPreservedCallback.mdx b/docs/docs/react/hooks/useAsyncPreservedCallback.mdx
index f1e777790..9cf7fab27 100644
--- a/docs/docs/react/hooks/useAsyncPreservedCallback.mdx
+++ b/docs/docs/react/hooks/useAsyncPreservedCallback.mdx
@@ -1,11 +1,14 @@
# useAsyncPreservedCallback
-[usePreservedCallback](https://modern-agile-team.github.io/modern-kit/docs/react/hooks/usePreservedCallback) 과 유사하나 Promise를 반환하는 커스텀 훅입니다.
+[usePreservedCallback](https://modern-agile-team.github.io/modern-kit/docs/react/hooks/usePreservedCallback) 과 유사하나 `Promise`를 반환하는 커스텀 훅입니다.
+## Code
+[🔗 실제 구현 코드 확인](https://github.com/modern-agile-team/modern-kit/blob/main/packages/react/src/hooks/useAsyncPreservedCallback/index.ts)
+
## Interface
-```tsx
+```ts title="typescript"
const useAsyncPreservedCallback: Promise>(
callback: T
) => (...args: any[]) => Promise;
diff --git a/docs/docs/react/hooks/useBlockPromiseMultipleClick.mdx b/docs/docs/react/hooks/useBlockPromiseMultipleClick.mdx
index f47aa6286..6bca2e456 100644
--- a/docs/docs/react/hooks/useBlockPromiseMultipleClick.mdx
+++ b/docs/docs/react/hooks/useBlockPromiseMultipleClick.mdx
@@ -11,8 +11,11 @@ import { useBlockPromiseMultipleClick } from '@modern-kit/react';
+## Code
+[🔗 실제 구현 코드 확인](https://github.com/modern-agile-team/modern-kit/blob/main/packages/react/src/hooks/useBlockPromiseMultipleClick/index.ts)
+
## Interface
-```tsx
+```ts title="typescript"
const useBlockPromiseMultipleClick: () => {
isLoading: boolean;
blockMultipleClick: (callback: () => Promise) => Promise;
@@ -21,7 +24,7 @@ const useBlockPromiseMultipleClick: () => {
## Usage
-```tsx
+```tsx title="typescript"
import React, { useState } from 'react';
import { useBlockPromiseMultipleClick } from '@modern-kit/react';
diff --git a/docs/docs/react/hooks/useDebounce.mdx b/docs/docs/react/hooks/useDebounce.mdx
index c4d4af921..848667792 100644
--- a/docs/docs/react/hooks/useDebounce.mdx
+++ b/docs/docs/react/hooks/useDebounce.mdx
@@ -7,8 +7,11 @@ import { useDebounce } from '@modern-kit/react'
+## Code
+[🔗 실제 구현 코드 확인](https://github.com/modern-agile-team/modern-kit/blob/main/packages/react/src/hooks/useDebounce/index.ts)
+
## Interface
-```tsx
+```ts title="typescript"
// lodash-es DebounceSettings
// https://www.geeksforgeeks.org/lodash-_-debounce-method/
interface DebounceSettings {
@@ -27,8 +30,7 @@ const useDebounce: (
```
## Usage
-
-```tsx
+```tsx title="typescript"
import { useState } from 'react';
import { useDebounce } from '@modern-kit/react';
diff --git a/docs/docs/react/hooks/useFileReader.mdx b/docs/docs/react/hooks/useFileReader.mdx
index 1f026c6b4..7e2975e46 100644
--- a/docs/docs/react/hooks/useFileReader.mdx
+++ b/docs/docs/react/hooks/useFileReader.mdx
@@ -4,8 +4,11 @@
+## Code
+[🔗 실제 구현 코드 확인](https://github.com/modern-agile-team/modern-kit/blob/main/packages/react/src/hooks/useFileReader/index.ts)
+
## Interface
-```tsx
+```ts title="typescript"
type ReadType = 'readAsText' | 'readAsDataURL' | 'readAsArrayBuffer';
interface FileContent {
@@ -32,8 +35,7 @@ const useFileReader: () => {
```
## Usage
-
-```tsx
+```tsx title="typescript"
import React, { useState } from 'react';
import { useFileReader } from '@modern-kit/react';
diff --git a/docs/docs/react/hooks/useForceUpdate.mdx b/docs/docs/react/hooks/useForceUpdate.mdx
index fe745ce4e..93e835acd 100644
--- a/docs/docs/react/hooks/useForceUpdate.mdx
+++ b/docs/docs/react/hooks/useForceUpdate.mdx
@@ -4,15 +4,17 @@
+## Code
+[🔗 실제 구현 코드 확인](https://github.com/modern-agile-team/modern-kit/blob/main/packages/react/src/hooks/useForceUpdate/index.ts)
+
## Interface
-```tsx
+```ts title="typescript"
// type DispatchWithoutAction = () => void;
const useForceUpdate: () => React.DispatchWithoutAction
```
## Usage
-
-```tsx
+```tsx title="typescript"
import { useForceUpdate } from '@modern-kit/react';
const Example = () => {
diff --git a/docs/docs/react/hooks/useImageStatus.mdx b/docs/docs/react/hooks/useImageStatus.mdx
index 9b5605304..e6d359875 100644
--- a/docs/docs/react/hooks/useImageStatus.mdx
+++ b/docs/docs/react/hooks/useImageStatus.mdx
@@ -4,8 +4,11 @@
+## Code
+[🔗 실제 구현 코드 확인](https://github.com/modern-agile-team/modern-kit/blob/main/packages/react/src/hooks/useImageStatus/index.ts)
+
## Interface
-```tsx
+```ts title="typescript"
type ImageStatus = 'pending' | 'loading' | 'complete' | 'error';
const useImageStatus: () => {
@@ -15,8 +18,7 @@ const useImageStatus: () => {
```
## Usage
-
-```tsx
+```tsx title="typescript"
import { useImageStatus } from '@modern-kit/react';
import img1 from '../assets/img1.png';
diff --git a/docs/docs/react/hooks/useIntersectionObserver.mdx b/docs/docs/react/hooks/useIntersectionObserver.mdx
index 726022a93..3aa464b1f 100644
--- a/docs/docs/react/hooks/useIntersectionObserver.mdx
+++ b/docs/docs/react/hooks/useIntersectionObserver.mdx
@@ -6,8 +6,11 @@ Intersection Observer Option을 설정할 수 있습니다.(하단 `Note` 참고
+## Code
+[🔗 실제 구현 코드 확인](https://github.com/modern-agile-team/modern-kit/blob/main/packages/react/src/hooks/useIntersectionObserver/index.ts)
+
## Interface
-```tsx
+```ts title="typescript"
interface UseIntersectionObserverProps extends IntersectionObserverInit {
action: (entry: IntersectionObserverEntry) => void;
calledOnce?: boolean;
@@ -23,8 +26,7 @@ const useIntersectionObserver: ({
```
## Usage
-
-```tsx
+```tsx title="typescript"
import { useIntersectionObserver } from '@modern-kit/react';
const Example = () => {
diff --git a/docs/docs/react/hooks/useInterval.mdx b/docs/docs/react/hooks/useInterval.mdx
index 51de91736..c63b93311 100644
--- a/docs/docs/react/hooks/useInterval.mdx
+++ b/docs/docs/react/hooks/useInterval.mdx
@@ -8,16 +8,18 @@
+## Code
+[🔗 실제 구현 코드 확인](https://github.com/modern-agile-team/modern-kit/blob/main/packages/react/src/hooks/useInterval/index.ts)
+
## Interface
-```tsx
+```ts title="typescript"
type SetIntervalParameters = Parameters;
const useInterval: (callback: SetIntervalParameters[0], delay?: SetIntervalParameters[1]) => void
```
## Usage
-
-```tsx
+```tsx title="typescript"
import { useInterval } from '@modern-kit/react';
const Example = () => {
diff --git a/docs/docs/react/hooks/useIsMounted.mdx b/docs/docs/react/hooks/useIsMounted.mdx
index a50beebca..42ac24fae 100644
--- a/docs/docs/react/hooks/useIsMounted.mdx
+++ b/docs/docs/react/hooks/useIsMounted.mdx
@@ -6,14 +6,16 @@
+## Code
+[🔗 실제 구현 코드 확인](https://github.com/modern-agile-team/modern-kit/blob/main/packages/react/src/hooks/useIsMounted/index.ts)
+
## Interface
-```tsx
+```ts title="typescript"
const useIsMounted: () => boolean
```
## Usage
-
-```tsx
+```tsx title="typescript"
import { useIsMounted } from '@modern-kit/react';
const Example = () => {
diff --git a/docs/docs/react/hooks/useIsomorphicLayoutEffect.mdx b/docs/docs/react/hooks/useIsomorphicLayoutEffect.mdx
index 3675ddd49..c0136d0c6 100644
--- a/docs/docs/react/hooks/useIsomorphicLayoutEffect.mdx
+++ b/docs/docs/react/hooks/useIsomorphicLayoutEffect.mdx
@@ -6,8 +6,11 @@ client환경에서는 `useLayoutEffect`를 사용하고, server환경에서는 `
+## Code
+[🔗 실제 구현 코드 확인](https://github.com/modern-agile-team/modern-kit/blob/main/packages/react/src/hooks/useIsomorphicLayoutEffect/index.ts)
+
## Interface
-```tsx
+```ts title="typescript"
const useIsomorphicLayoutEffect: (
effect: React.EffectCallback,
deps?: React.DependencyList | undefined
@@ -15,8 +18,7 @@ const useIsomorphicLayoutEffect: (
```
## Usage
-
-```tsx
+```tsx title="typescript"
import { useIsomorphicLayoutEffect } from '@modern-kit/react';
const Example = () => {
diff --git a/docs/docs/react/hooks/useMediaQuery.mdx b/docs/docs/react/hooks/useMediaQuery.mdx
index 9d8457dc9..381389e95 100644
--- a/docs/docs/react/hooks/useMediaQuery.mdx
+++ b/docs/docs/react/hooks/useMediaQuery.mdx
@@ -6,16 +6,18 @@ Resize 시에도 동작하며, 미디어 쿼리 문자열의 분석 결과를
+## Code
+[🔗 실제 구현 코드 확인](https://github.com/modern-agile-team/modern-kit/blob/main/packages/react/src/hooks/useMediaQuery/index.ts)
+
## Interface
-```tsx
+```ts title="typescript"
const useMediaQuery: (query: string) => {
- isMatch: boolean;
+ isMatch: boolean;
}
```
## Usage
-
-```tsx
+```tsx title="typescript"
import { useMediaQuery } from '@modern-kit/react';
const Example = () => {
@@ -31,7 +33,6 @@ const Example = () => {
);
};
-
```
export const Example = () => {
diff --git a/docs/docs/react/hooks/useMergeRefs.mdx b/docs/docs/react/hooks/useMergeRefs.mdx
index 0f3e10e00..7496d9c2b 100644
--- a/docs/docs/react/hooks/useMergeRefs.mdx
+++ b/docs/docs/react/hooks/useMergeRefs.mdx
@@ -4,8 +4,12 @@
+## Code
+[🔗 실제 구현 코드 확인](https://github.com/modern-agile-team/modern-kit/blob/main/packages/react/src/hooks/useMergeRefs/index.ts)
+
## Interface
-```tsx
+
+```ts title="typescript"
const useMergeRefs: (
...refs: (React.MutableRefObject | React.LegacyRef)[]
) => (instance: T | null) => void;
@@ -13,7 +17,7 @@ const useMergeRefs: (
## Usage
-```tsx
+```tsx title="typescript"
import React, { forwardRef, useRef } from 'react';
import { useMergeRefs } from '@modern-kit/react';
diff --git a/docs/docs/react/hooks/useOnClickOutside.mdx b/docs/docs/react/hooks/useOnClickOutside.mdx
index 686d0ccf0..3a11cf19e 100644
--- a/docs/docs/react/hooks/useOnClickOutside.mdx
+++ b/docs/docs/react/hooks/useOnClickOutside.mdx
@@ -4,8 +4,12 @@
+## Code
+[🔗 실제 구현 코드 확인](https://github.com/modern-agile-team/modern-kit/blob/main/packages/react/src/hooks/useOnClickOutside/index.ts)
+
## Interface
-```tsx
+
+```ts title="typescript"
const useOnClickOutside: (
action: (targetElement: T) => void
) => {
@@ -14,8 +18,7 @@ const useOnClickOutside: (
```
## Usage
-
-```tsx
+```tsx title="typescript"
import { useMemo } from 'react';
import { useOnClickOutside } from '@modern-kit/react';
diff --git a/docs/docs/react/hooks/usePreservedCallback.mdx b/docs/docs/react/hooks/usePreservedCallback.mdx
index 1cb408bfd..ffa5c096f 100644
--- a/docs/docs/react/hooks/usePreservedCallback.mdx
+++ b/docs/docs/react/hooks/usePreservedCallback.mdx
@@ -6,8 +6,11 @@
+## Code
+[🔗 실제 구현 코드 확인](https://github.com/modern-agile-team/modern-kit/blob/main/packages/react/src/hooks/usePreservedCallback/index.ts)
+
## Interface
-```tsx
+```ts title="typescript"
const usePreservedCallback: any>(
callback: T
) => (...args: any[]) => any;
@@ -15,7 +18,7 @@ const usePreservedCallback: any>(
## Usage
### as-is
-```tsx
+```tsx title="typescript"
import React, { useEffect, useState } from "react";
const Example = () => {
@@ -36,7 +39,7 @@ const Example = () => {
```
### to-be (usePreservedCallback)
-```tsx
+```tsx title="typescript"
import React, { useEffect, useState } from "react";
import { usePreservedCallback } from '@modern-kit/react';
diff --git a/docs/docs/react/hooks/usePreservedState.mdx b/docs/docs/react/hooks/usePreservedState.mdx
index de25ca6c9..814c2e7dc 100644
--- a/docs/docs/react/hooks/usePreservedState.mdx
+++ b/docs/docs/react/hooks/usePreservedState.mdx
@@ -9,8 +9,11 @@ comparator를 넘기지 않는다면 `@modern-kit/utils`의 `deepEqual` 함수
+## Code
+[🔗 실제 구현 코드 확인](https://github.com/modern-agile-team/modern-kit/blob/main/packages/react/src/hooks/usePreservedState/index.ts)
+
## Interface
-```tsx
+```ts title="typescript"
const usePreservedState: (
value: T,
comparator?: ((source: T, target: T) => boolean) | undefined
@@ -19,7 +22,7 @@ const usePreservedState: (
## Usage
### Default Comparator
-```tsx
+```tsx title="typescript"
import React, { useEffect, useState } from "react";
import { usePreservedState } from "@modern-kit/react";
@@ -33,7 +36,7 @@ const Example = () => {
### Custom Comparator
-```tsx
+```tsx title="typescript"
import React, { useEffect, useState } from 'react';
import { usePreservedState } from '@modern-kit/react';
@@ -47,5 +50,4 @@ const Example = () => {
return <>{/* ... */}>;
};
-
```
\ No newline at end of file
diff --git a/docs/docs/react/hooks/usePrevious.mdx b/docs/docs/react/hooks/usePrevious.mdx
index c3087bbbe..cae3b20f3 100644
--- a/docs/docs/react/hooks/usePrevious.mdx
+++ b/docs/docs/react/hooks/usePrevious.mdx
@@ -7,14 +7,16 @@ import { useState } from 'react';
+## Code
+[🔗 실제 구현 코드 확인](https://github.com/modern-agile-team/modern-kit/blob/main/packages/react/src/hooks/usePrevious/index.ts)
+
## Interface
-```tsx
+```ts title="typescript"
const usePrevious: (value: T) => T;
```
## Usage
-
-```tsx
+```tsx title="typescript"
import { useState } from 'react';
import { usePrevious } from '@modern-kit/react';
diff --git a/docs/docs/react/hooks/useResizeObserver.mdx b/docs/docs/react/hooks/useResizeObserver.mdx
index d9ed28ac8..3da1decac 100644
--- a/docs/docs/react/hooks/useResizeObserver.mdx
+++ b/docs/docs/react/hooks/useResizeObserver.mdx
@@ -6,8 +6,11 @@ import { useResizeObserver } from '@modern-kit/react';
+## Code
+[🔗 실제 구현 코드 확인](https://github.com/modern-agile-team/modern-kit/blob/main/packages/react/src/hooks/useResizeObserver/index.ts)
+
## Interface
-```tsx
+```ts title="typescript"
/**
* type ContentRect = {
readonly bottom: number;
@@ -31,8 +34,7 @@ const useResizeObserver: (
```
## Usage
-
-```tsx
+```tsx title="typescript"
import React, { forwardRef, useRef } from 'react';
import { useResizeObserver } from '@modern-kit/react';
diff --git a/docs/docs/react/hooks/useTimeout.mdx b/docs/docs/react/hooks/useTimeout.mdx
index fcfd01b84..690f02a1f 100644
--- a/docs/docs/react/hooks/useTimeout.mdx
+++ b/docs/docs/react/hooks/useTimeout.mdx
@@ -6,16 +6,18 @@
+## Code
+[🔗 실제 구현 코드 확인](https://github.com/modern-agile-team/modern-kit/blob/main/packages/react/src/hooks/useTimeout/index.ts)
+
## Interface
-```tsx
+```ts title="typescript"
type SetTimeoutParameters = Parameters;
const useTimeout: (callback: SetTimeoutParameters[0], delay?: SetTimeoutParameters[1]) => void
```
## Usage
-
-```tsx
+```tsx title="typescript"
import { useTimeout } from '@modern-kit/react';
const Example = () => {
diff --git a/docs/docs/react/hooks/useToggle.mdx b/docs/docs/react/hooks/useToggle.mdx
index 911bb7c8d..57a75ce36 100644
--- a/docs/docs/react/hooks/useToggle.mdx
+++ b/docs/docs/react/hooks/useToggle.mdx
@@ -4,14 +4,16 @@ boolean 타입의 state를 Toggle로 쉽게 사용할 수 있는 커스텀 훅
+## Code
+[🔗 실제 구현 코드 확인](https://github.com/modern-agile-team/modern-kit/blob/main/packages/react/src/hooks/useToggle/index.ts)
+
## Interface
-```tsx
+```ts title="typescript"
const useToggle: (defaultValue?: boolean) => readonly [boolean, () => void]
```
## Usage
-
-```tsx
+```tsx title="typescript"
import { useToggle } from '@modern-kit/react';
const Example = () => {
diff --git a/docs/docs/react/hooks/useUnmount.mdx b/docs/docs/react/hooks/useUnmount.mdx
index 305f15947..739ed4eaf 100644
--- a/docs/docs/react/hooks/useUnmount.mdx
+++ b/docs/docs/react/hooks/useUnmount.mdx
@@ -4,14 +4,16 @@
+## Code
+[🔗 실제 구현 코드 확인](https://github.com/modern-agile-team/modern-kit/blob/main/packages/react/src/hooks/useUnMount/index.ts)
+
## Interface
-```tsx
+```ts title="typescript"
const useUnmount: (callback: () => any) => void
```
## Usage
-
-```tsx
+```tsx title="typescript"
import { useUnmount } from '@modern-kit/react';
const Example = () => {
diff --git a/docs/docs/react/hooks/useVisibilityChange.mdx b/docs/docs/react/hooks/useVisibilityChange.mdx
index 8be261f25..7dfcdf300 100644
--- a/docs/docs/react/hooks/useVisibilityChange.mdx
+++ b/docs/docs/react/hooks/useVisibilityChange.mdx
@@ -4,8 +4,11 @@
+## Code
+[🔗 실제 구현 코드 확인](https://github.com/modern-agile-team/modern-kit/blob/main/packages/react/src/hooks/useVisibilityChange/index.ts)
+
## Interface
-```tsx
+```ts title="typescript"
type VisibilityChangeCallbackAction = (
event: Event,
visibilityState: DocumentVisibilityState
@@ -20,7 +23,7 @@ const useVisibilityChange: ({ onShow, onHide, }: useVisibilityChangeProps) => vo
```
## Usage
-```tsx
+```tsx title="typescript"
import { useVisibilityChange } from '@modern-kit/react';
const Example = () => {
diff --git a/docs/docs/react/hooks/useWindowScrollTo.mdx b/docs/docs/react/hooks/useWindowScrollTo.mdx
index 3b6da9016..daf4ec5a2 100644
--- a/docs/docs/react/hooks/useWindowScrollTo.mdx
+++ b/docs/docs/react/hooks/useWindowScrollTo.mdx
@@ -4,8 +4,11 @@
+## Code
+[🔗 실제 구현 코드 확인](https://github.com/modern-agile-team/modern-kit/blob/main/packages/react/src/hooks/useWindowScrollTo/index.ts)
+
## Interface
-```tsx
+```ts title="typescript"
interface UseScrollToProps {
left?: ScrollToOptions['left']; // default: 0
top?: ScrollToOptions['top']; // default: 0
@@ -22,7 +25,7 @@ const useWindowScrollTo: ({
```
## Usage
-```tsx
+```tsx title="typescript"
import { useWindowScrollTo } from '@modern-kit/react';
const Example = () => {
diff --git a/docs/docs/react/hooks/useWindowSize.mdx b/docs/docs/react/hooks/useWindowSize.mdx
index 657e8a480..55378c79a 100644
--- a/docs/docs/react/hooks/useWindowSize.mdx
+++ b/docs/docs/react/hooks/useWindowSize.mdx
@@ -7,8 +7,11 @@ import { useMemo } from 'react';
+## Code
+[🔗 실제 구현 코드 확인](https://github.com/modern-agile-team/modern-kit/blob/main/packages/react/src/hooks/useWindowSize/index.ts)
+
## Interface
-```tsx
+```ts title="typescript"
interface Size {
width: number | null;
height: number | null;
@@ -24,7 +27,7 @@ const useWindowSize: (options?: useWindowSizeProps) => Size
## Usage
### Default
-```tsx
+```tsx title="typescript"
import { useWindowSize } from '@modern-kit/react';
const Example = () => {
@@ -72,7 +75,7 @@ export const DefaultExample = () => {
### Debounce
-```tsx
+```tsx title="typescript"
import { useWindowSize } from '@modern-kit/react';
const DebounceExample = () => {
diff --git a/docs/docs/utils/common/abRandom.md b/docs/docs/utils/common/abRandom.md
index e5e6d5bf2..39c39457e 100644
--- a/docs/docs/utils/common/abRandom.md
+++ b/docs/docs/utils/common/abRandom.md
@@ -4,16 +4,18 @@
`AB 테스트`를 할 때 활용할 수 있습니다.
-
+## Code
+[🔗 실제 구현 코드 확인](https://github.com/modern-agile-team/modern-kit/blob/main/packages/utils/src/common/abRandom/index.ts)
+
## Interface
-```tsx
+```ts title="typescript"
const abRandom: () => 0 | 1
```
## Usage
-```ts
+```ts title="typescript"
import { abRandom } from '@modern-kit/utils';
const ab = abRandom();
diff --git a/docs/docs/utils/common/asyncNoop.md b/docs/docs/utils/common/asyncNoop.md
index fed11f2de..d2536a87c 100644
--- a/docs/docs/utils/common/asyncNoop.md
+++ b/docs/docs/utils/common/asyncNoop.md
@@ -4,13 +4,15 @@
+[🔗 실제 구현 코드 확인](https://github.com/modern-agile-team/modern-kit/blob/main/packages/utils/src/common/asyncNoop/index.ts)
+
## Interface
-```tsx
+```ts title="typescript"
const asyncNoop: () => Promise
```
## Usage
-```ts
+```ts title="typescript"
import { asyncNoop } from '@modern-kit/utils';
const handleAsyncClick = (callback = asyncNoop) => {
diff --git a/docs/docs/utils/common/deepCopy.md b/docs/docs/utils/common/deepCopy.md
index 31bbd8df2..a4f0b0ab1 100644
--- a/docs/docs/utils/common/deepCopy.md
+++ b/docs/docs/utils/common/deepCopy.md
@@ -4,13 +4,16 @@
+## Code
+[🔗 실제 구현 코드 확인](https://github.com/modern-agile-team/modern-kit/blob/main/packages/utils/src/common/deepCopy/index.ts)
+
## Interface
-```tsx
+```ts title="typescript"
const deepCopy: (source: T) => T
```
## Usage
-```ts
+```ts title="typescript"
import { deepCopy } from '@modern-kit/utils';
const originNum = 42;
diff --git a/docs/docs/utils/common/deepEqual.md b/docs/docs/utils/common/deepEqual.md
index f471a56a2..17c3d76f8 100644
--- a/docs/docs/utils/common/deepEqual.md
+++ b/docs/docs/utils/common/deepEqual.md
@@ -4,13 +4,16 @@
+## Code
+[🔗 실제 구현 코드 확인](https://github.com/modern-agile-team/modern-kit/blob/main/packages/utils/src/common/deepEqual/index.ts)
+
## Interface
-```tsx
+```ts title="typescript"
const deepEqual: (source: any, target: any) => boolean
```
## Usage
-```ts
+```ts title="typescript"
import { deepEqual } from '@modern-kit/utils';
const isEqual1 = deepEqual(1, 1); // true
diff --git a/docs/docs/utils/common/delay.md b/docs/docs/utils/common/delay.md
index 4182b7b44..f65509a3c 100644
--- a/docs/docs/utils/common/delay.md
+++ b/docs/docs/utils/common/delay.md
@@ -6,13 +6,16 @@ setTimeout을 사용하여 특정 시간 뒤의 동작을 정의할 경우, 해
+## Code
+[🔗 실제 구현 코드 확인](https://github.com/modern-agile-team/modern-kit/blob/main/packages/utils/src/common/delay/index.ts)
+
## Interface
-```tsx
+```ts title="typescript"
const delay: (time: number) => Promise
```
## Usage
-```ts
+```ts title="typescript"
import { delay } from '@modern-kit/utils';
const something = () => Promise.resolve()
diff --git a/docs/docs/utils/common/getUniqId.md b/docs/docs/utils/common/getUniqId.md
index 09e9f75a7..013116d00 100644
--- a/docs/docs/utils/common/getUniqId.md
+++ b/docs/docs/utils/common/getUniqId.md
@@ -2,16 +2,18 @@
`유니크한 아이디`를 반환하는 함수입니다.
-
+## Code
+[🔗 실제 구현 코드 확인](https://github.com/modern-agile-team/modern-kit/blob/main/packages/utils/src/common/getUniqId/index.ts)
+
## Interface
-```tsx
+```ts title="typescript"
const getUniqId: () => string
```
## Usage
-```ts
+```ts title="typescript"
import { getUniqId } from '@modern-kit/utils';
const uniqId = getUniqId();
diff --git a/docs/docs/utils/common/getUniqTime.md b/docs/docs/utils/common/getUniqTime.md
index 86a7fc15b..2c8103c95 100644
--- a/docs/docs/utils/common/getUniqTime.md
+++ b/docs/docs/utils/common/getUniqTime.md
@@ -2,16 +2,18 @@
기본적으로 `new Date().getTime()` 값을 반환하는 함수이지만, 동일 시간에 여러번 호출 할 경우 유니크 값을 반환하는 함수입니다.
-
+## Code
+[🔗 실제 구현 코드 확인](https://github.com/modern-agile-team/modern-kit/blob/main/packages/utils/src/common/getUniqTime/index.ts)
+
## Interface
-```tsx
+```ts title="typescript"
const getUniqTime: () => number
```
## Usage
-```ts
+```ts title="typescript"
import { getUniqTime } from '@modern-kit/utils';
const uniqTime = getUniqTime();
diff --git a/docs/docs/utils/common/getViewportSize.md b/docs/docs/utils/common/getViewportSize.md
index f378ede14..ec75a448a 100644
--- a/docs/docs/utils/common/getViewportSize.md
+++ b/docs/docs/utils/common/getViewportSize.md
@@ -5,8 +5,11 @@
+## Code
+[🔗 실제 구현 코드 확인](https://github.com/modern-agile-team/modern-kit/blob/main/packages/utils/src/common/getViewportSize/index.tsx)
+
## Interface
-```tsx
+```ts title="typescript"
const getViewportSize: () => {
readonly width: number;
readonly height: number;
@@ -14,7 +17,7 @@ const getViewportSize: () => {
```
## Usage
-```ts
+```ts title="typescript"
import { getViewportSize } from '@modern-kit/utils';
const { width, height } = getViewportSize();
diff --git a/docs/docs/utils/common/hexToRgba.md b/docs/docs/utils/common/hexToRgba.md
index d3f70753f..04e138633 100644
--- a/docs/docs/utils/common/hexToRgba.md
+++ b/docs/docs/utils/common/hexToRgba.md
@@ -6,8 +6,11 @@
+## Code
+[🔗 실제 구현 코드 확인](https://github.com/modern-agile-team/modern-kit/blob/main/packages/utils/src/common/hexToRgba/index.ts)
+
## Interface
-```tsx
+```ts title="typescript"
const hexToRgba: (hex: string, alpha?: number) => {
readonly r: number;
readonly g: number;
@@ -18,7 +21,7 @@ const hexToRgba: (hex: string, alpha?: number) => {
```
## Usage
-```ts
+```ts title="typescript"
import { hexToRgba } from '@modern-kit/utils';
const hex1 = '#1A2B3C';
diff --git a/docs/docs/utils/common/noop.md b/docs/docs/utils/common/noop.md
index 63e67d500..e60201f18 100644
--- a/docs/docs/utils/common/noop.md
+++ b/docs/docs/utils/common/noop.md
@@ -4,13 +4,16 @@
+## Code
+[🔗 실제 구현 코드 확인](https://github.com/modern-agile-team/modern-kit/blob/main/packages/utils/src/common/noop/index.ts)
+
## Interface
-```tsx
+```ts title="typescript"
const noop: () => void
```
## Usage
-```ts
+```ts title="typescript"
import { noop } from '@modern-kit/utils';
const handleClick = (callback = noop) => {
diff --git a/docs/docs/utils/common/parseJson.md b/docs/docs/utils/common/parseJson.md
index 32ba42ce1..3f216463e 100644
--- a/docs/docs/utils/common/parseJson.md
+++ b/docs/docs/utils/common/parseJson.md
@@ -1,23 +1,28 @@
# parseJson
-일반적으로 JSON.parse를 사용하는 경우 일부 input값(ex. 빈 문자열, undefined, NaN)에 대해서는 에러를 반환합니다. 이 함수를 사용하면 에러를 반환하는 값에 대해서는 null을 반환하여 파싱 시의 예상치 못한 에러를 방지할 수 있습니다.
+일반적으로 `JSON.parse`를 사용하는 경우 일부 input값(ex. `빈 문자열("")`, `undefined`, `NaN`)에 대해서는 에러를 발생시킵니다.
+
+이 함수를 사용하면 에러를 반환하는 값에 대해서는 `null`을 반환하여 파싱 시의 예상치 못한 에러를 방지할 수 있습니다.
+## Code
+[🔗 실제 구현 코드 확인](https://github.com/modern-agile-team/modern-kit/blob/main/packages/utils/src/common/parseJson/index.ts)
+
## Interface
-```tsx
+```ts title="typescript"
const parseJson: (value: any) => T | null
```
## Usage
-```ts
+```ts title="typescript"
import { parseJson } from '@modern-kit/utils';
type NormalObject = { a: 1, b: 2 }
-const normalObject = parseJSON(`{ "a": 1, "b": 2 }`); // { a: 1, b: 2 } | null
-const emptyString = parseJSON<''>(''); // '' | null
+const normalObject = parseJSON(`{ "a": 1, "b": 2 }`); // { a: 1, b: 2 }
+const emptyString = parseJSON<''>(''); // ''
const nullValue = parseJSON(null); // null
-const undefinedValue = parseJSON(undefined); // undefined | null
-const NaNValue = parseJSON(NaN); // number | null
+const undefinedValue = parseJSON(undefined); // undefined
+const NaNValue = parseJSON(NaN); // null
```
\ No newline at end of file
diff --git a/docs/docs/utils/common/wrapInArray.md b/docs/docs/utils/common/wrapInArray.md
index 36617dd94..81249ac87 100644
--- a/docs/docs/utils/common/wrapInArray.md
+++ b/docs/docs/utils/common/wrapInArray.md
@@ -6,13 +6,17 @@
+## Code
+[🔗 실제 구현 코드 확인](https://github.com/modern-agile-team/modern-kit/blob/main/packages/utils/src/common/wrapInArray/index.ts)
+
+
## Interface
-```tsx
+```ts title="typescript"
const wrapInArray: (value: T | T[]) => T[]
```
## Usage
-```ts
+```ts title="typescript"
import { wrapInArray } from '@modern-kit/utils';
const wrappedInArray1 = wrapInArray('ModernKit'); // ['ModernKit']
diff --git a/docs/docs/utils/device/getOS.md b/docs/docs/utils/device/getOS.md
index b3a6bd39d..6df5b5cb0 100644
--- a/docs/docs/utils/device/getOS.md
+++ b/docs/docs/utils/device/getOS.md
@@ -10,13 +10,16 @@
+## Code
+[🔗 실제 구현 코드 확인](https://github.com/modern-agile-team/modern-kit/blob/main/packages/utils/src/device/getOS/index.ts)
+
## Interface
-```tsx
+```ts title="typescript"
const getOS: () => "server" | "ios" | "android" | "otherMobile" | "web"
```
## Usage
-```ts
+```ts title="typescript"
import { getOS } from '@modern-kit/utils';
const os = getOS();
diff --git a/docs/docs/utils/device/isClient.md b/docs/docs/utils/device/isClient.md
index af44e12fc..c367e7f5a 100644
--- a/docs/docs/utils/device/isClient.md
+++ b/docs/docs/utils/device/isClient.md
@@ -6,13 +6,16 @@
+## Code
+[🔗 실제 구현 코드 확인](https://github.com/modern-agile-team/modern-kit/blob/main/packages/utils/src/device/isClient/index.ts)
+
## Interface
-```tsx
+```ts title="typescript"
const isClient: () => boolean
```
## Usage
-```ts
+```ts title="typescript"
import { isClient } from '@modern-kit/utils';
if (isClient()) {
diff --git a/docs/docs/utils/device/isMobile.md b/docs/docs/utils/device/isMobile.md
index 91bd78b2c..5eea14ebc 100644
--- a/docs/docs/utils/device/isMobile.md
+++ b/docs/docs/utils/device/isMobile.md
@@ -2,16 +2,18 @@
`모바일 환경`인지 확인하는 함수입니다.
-
+## Code
+[🔗 실제 구현 코드 확인](https://github.com/modern-agile-team/modern-kit/blob/main/packages/utils/src/device/isMobile/index.ts)
+
## Interface
-```tsx
+```ts title="typescript"
const isMobile: () => boolean
```
## Usage
-```ts
+```ts title="typescript"
import { isMobile } from '@modern-kit/utils';
if (isMobile()) {
diff --git a/docs/docs/utils/device/isSever.md b/docs/docs/utils/device/isSever.md
index b3050d325..e9ae57b4f 100644
--- a/docs/docs/utils/device/isSever.md
+++ b/docs/docs/utils/device/isSever.md
@@ -6,13 +6,16 @@
+## Code
+[🔗 실제 구현 코드 확인](https://github.com/modern-agile-team/modern-kit/blob/main/packages/utils/src/device/isServer/index.ts)
+
## Interface
-```tsx
+```ts title="typescript"
const isServer: () => boolean
```
## Usage
-```ts
+```ts title="typescript"
import { isServer } from '@modern-kit/utils';
if (isServer()) {
diff --git a/docs/docs/utils/formatter/formatNumberByUnits.md b/docs/docs/utils/formatter/formatNumberByUnits.md
index 497217d44..486c9c0e6 100644
--- a/docs/docs/utils/formatter/formatNumberByUnits.md
+++ b/docs/docs/utils/formatter/formatNumberByUnits.md
@@ -4,8 +4,11 @@
+## Code
+[🔗 실제 구현 코드 확인](https://github.com/modern-agile-team/modern-kit/blob/main/packages/utils/src/formatter/formatNumberByUnits/index.ts)
+
## Interface
-```tsx
+```ts title="typescript"
interface Unit {
unit: string;
value: number;
@@ -36,7 +39,7 @@ const formatNumberByUnits: (
```
## Usage
-```ts
+```ts title="typescript"
import { formatNumberByUnits } from '@modern-kit/utils';
const ONE_HUNDRED_MILLION = 100000000;
diff --git a/docs/docs/utils/formatter/formatNumberCurrency.md b/docs/docs/utils/formatter/formatNumberCurrency.md
index 5f7c96df4..3590ce7f0 100644
--- a/docs/docs/utils/formatter/formatNumberCurrency.md
+++ b/docs/docs/utils/formatter/formatNumberCurrency.md
@@ -4,8 +4,11 @@
+## Code
+[🔗 실제 구현 코드 확인](https://github.com/modern-agile-team/modern-kit/blob/main/packages/utils/src/formatter/formatNumberCurrency/index.ts)
+
## Interface
-```tsx
+```ts title="typescript"
interface CurrencyOption {
currency: string;
currencyPosition: 'prefix' | 'suffix';
@@ -31,7 +34,7 @@ const formatNumberCurrency: (
## Usage
### Basic
기본적인 사용법은 아래와 같습니다.
-```ts
+```ts title="typescript"
import { formatNumberCurrency } from '@modern-kit/utils';
const ONE_HUNDRED_MILLION = 100000000;
@@ -84,7 +87,7 @@ const value4 = formatNumberCurrency(459325300, {
### ⭐️Abstraction
아래와 같이 필요에 맞게 `추상화`해서 사용하는 것을 추천드립니다.
-```ts
+```ts title="typescript"
const ONE_HUNDRED_MILLION = 100000000;
const TEN_THOUSAND = 10000;
diff --git a/docs/docs/utils/formatter/formatNumberWithCommas.md b/docs/docs/utils/formatter/formatNumberWithCommas.md
index 59ea97f02..c4734dca7 100644
--- a/docs/docs/utils/formatter/formatNumberWithCommas.md
+++ b/docs/docs/utils/formatter/formatNumberWithCommas.md
@@ -4,13 +4,16 @@
+## Code
+[🔗 실제 구현 코드 확인](https://github.com/modern-agile-team/modern-kit/blob/main/packages/utils/src/formatter/formatNumberWithCommas/index.ts)
+
## Interface
-```tsx
+```ts title="typescript"
const formatNumberWithCommas: (value: string | number) => string
```
## Usage
-```ts
+```ts title="typescript"
import { formatNumberWithCommas } from '@modern-kit/utils';
const numberWithComma1 = formatNumberWithCommas(200); // '200'
diff --git a/docs/docs/utils/formatter/formatPhoneNumber.md b/docs/docs/utils/formatter/formatPhoneNumber.md
index eeea1d282..5d2c9d6c0 100644
--- a/docs/docs/utils/formatter/formatPhoneNumber.md
+++ b/docs/docs/utils/formatter/formatPhoneNumber.md
@@ -4,13 +4,16 @@
+## Code
+[🔗 실제 구현 코드 확인](https://github.com/modern-agile-team/modern-kit/blob/main/packages/utils/src/formatter/formatPhoneNumber/index.ts)
+
## Interface
-```tsx
+```ts title="typescript"
const formatPhoneNumber: (value: string) => string
```
## Usage
-```ts
+```ts title="typescript"
import { formatPhoneNumber } from '@modern-kit/utils';
const phoneNumber0 = formatPhoneNumber('03112345678'); // '031-1234-5678'
diff --git a/docs/docs/utils/object/deleteEmptyProperties.md b/docs/docs/utils/object/deleteEmptyProperties.md
index 2412c0f81..fa1f6a7cc 100644
--- a/docs/docs/utils/object/deleteEmptyProperties.md
+++ b/docs/docs/utils/object/deleteEmptyProperties.md
@@ -6,13 +6,16 @@
+## Code
+[🔗 실제 구현 코드 확인](https://github.com/modern-agile-team/modern-kit/blob/main/packages/utils/src/object/deleteFalsyProperties/index.ts)
+
## Interface
-```tsx
+```ts title="typescript"
const deleteEmptyProperties: >(obj: T) => T
```
## Usage
-```ts
+```ts title="typescript"
import { deleteEmptyProperties } from '@modern-kit/utils';
const obj = deleteEmptyProperties({
diff --git a/docs/docs/utils/object/mergeProperties.md b/docs/docs/utils/object/mergeProperties.md
index 40e3c77fd..92cbaf9dc 100644
--- a/docs/docs/utils/object/mergeProperties.md
+++ b/docs/docs/utils/object/mergeProperties.md
@@ -6,8 +6,11 @@ Key가 동일할 때 값이 원시 타입의 경우 source의 값으로 덮어
+## Code
+[🔗 실제 구현 코드 확인](https://github.com/modern-agile-team/modern-kit/blob/main/packages/utils/src/object/mergeProperties/index.ts)
+
## Interface
-```tsx
+```ts title="typescript"
const mergeProperties: <
T extends Record,
K extends Record
@@ -18,7 +21,7 @@ const mergeProperties: <
```
## Usage
-```ts
+```ts title="typescript"
import { mergeProperties } from '@modern-kit/utils';
const target = {
diff --git a/docs/docs/utils/object/objectEntries.md b/docs/docs/utils/object/objectEntries.md
index 58ecbbee7..ed2db44d2 100644
--- a/docs/docs/utils/object/objectEntries.md
+++ b/docs/docs/utils/object/objectEntries.md
@@ -4,8 +4,12 @@
+## Code
+[🔗 실제 구현 코드 확인](https://github.com/modern-agile-team/modern-kit/blob/main/packages/utils/src/object/objectEntries/index.ts)
+
+
## Interface
-```tsx
+```ts title="typescript"
type ObjectKeys> = Exclude<
keyof T,
symbol
@@ -17,7 +21,7 @@ const objectEntries: >(
```
## Usage
-```ts
+```ts title="typescript"
import { objectEntries } from '@modern-kit/utils';
const symbol = Symbol('d');
diff --git a/docs/docs/utils/object/objectKeys.md b/docs/docs/utils/object/objectKeys.md
index b5144bfa5..c7c25d315 100644
--- a/docs/docs/utils/object/objectKeys.md
+++ b/docs/docs/utils/object/objectKeys.md
@@ -5,8 +5,11 @@
+## Code
+[🔗 실제 구현 코드 확인](https://github.com/modern-agile-team/modern-kit/blob/main/packages/utils/src/object/objectKeys/index.ts)
+
## Interface
-```tsx
+```ts title="typescript"
type ObjectKeys> = Exclude<
keyof T,
symbol
@@ -18,7 +21,7 @@ const objectKeys: , T[keyof T]>>(
```
## Usage
-```ts
+```ts title="typescript"
import { objectKeys } from '@modern-kit/utils';
const symbol = Symbol('d');
diff --git a/docs/docs/utils/object/objectValues.md b/docs/docs/utils/object/objectValues.md
index 13124eaaa..1b49ed7ae 100644
--- a/docs/docs/utils/object/objectValues.md
+++ b/docs/docs/utils/object/objectValues.md
@@ -4,8 +4,11 @@
+## Code
+[🔗 실제 구현 코드 확인](https://github.com/modern-agile-team/modern-kit/blob/main/packages/utils/src/object/objectValues/index.ts)
+
## Interface
-```tsx
+```ts title="typescript"
type ObjectKeys> = Exclude<
keyof T,
symbol
@@ -17,7 +20,7 @@ const objectValues: >(
```
## Usage
-```ts
+```ts title="typescript"
import { objectValues } from '@modern-kit/utils';
const symbol = Symbol('d');
diff --git a/docs/docs/utils/object/omit.md b/docs/docs/utils/object/omit.md
index 23bbe85f9..e1c7b3c0f 100644
--- a/docs/docs/utils/object/omit.md
+++ b/docs/docs/utils/object/omit.md
@@ -6,8 +6,11 @@
+## Code
+[🔗 실제 구현 코드 확인](https://github.com/modern-agile-team/modern-kit/blob/main/packages/utils/src/object/omit/index.ts)
+
## Interface
-```tsx
+```ts title="typescript"
type ObjectKeys> = Exclude<
keyof T,
symbol
@@ -23,7 +26,7 @@ const omit: <
```
## Usage
-```ts
+```ts title="typescript"
import { omit } from '@modern-kit/utils';
const symbol = Symbol('d');
diff --git a/docs/docs/utils/object/pick.md b/docs/docs/utils/object/pick.md
index 84f09d1f8..340aeb0b4 100644
--- a/docs/docs/utils/object/pick.md
+++ b/docs/docs/utils/object/pick.md
@@ -6,8 +6,11 @@
+## Code
+[🔗 실제 구현 코드 확인](https://github.com/modern-agile-team/modern-kit/blob/main/packages/utils/src/object/pick/index.ts)
+
## Interface
-```tsx
+```ts title="typescript"
type ObjectKeys> = Exclude<
keyof T,
symbol
@@ -23,7 +26,7 @@ const pick: <
```
## Usage
-```ts
+```ts title="typescript"
import { pick } from '@modern-kit/utils';
const pickedObj1 = pick({ a: 1, b: 2, c: 3 }, 'b'); // { b: 2 }
diff --git a/docs/docs/utils/string/countSubstringOccurrences.md b/docs/docs/utils/string/countSubstringOccurrences.md
index 25b074f27..7fa9fbc16 100644
--- a/docs/docs/utils/string/countSubstringOccurrences.md
+++ b/docs/docs/utils/string/countSubstringOccurrences.md
@@ -4,13 +4,16 @@
+## Code
+[🔗 실제 구현 코드 확인](https://github.com/modern-agile-team/modern-kit/blob/main/packages/utils/src/string/countSubstringOccurrences/index.ts)
+
## Interface
-```tsx
+```ts title="typescript"
const countSubstringOccurrences: (source: string, target: string) => number
```
## Usage
-```ts
+```ts title="typescript"
import { countSubstringOccurrences } from '@modern-kit/utils';
const str = 'apple banana apple grapes apple';
diff --git a/docs/docs/utils/string/extractNumber.md b/docs/docs/utils/string/extractNumber.md
index 643acdf47..8cf3e9dcc 100644
--- a/docs/docs/utils/string/extractNumber.md
+++ b/docs/docs/utils/string/extractNumber.md
@@ -4,13 +4,16 @@
+## Code
+[🔗 실제 구현 코드 확인](https://github.com/modern-agile-team/modern-kit/blob/main/packages/utils/src/string/extractNumber/index.ts)
+
## Interface
-```tsx
+```ts title="typescript"
const extractNumber: (value: string) => string
```
## Usage
-```ts
+```ts title="typescript"
import { extractNumber } from '@modern-kit/utils';
const str1 = extractNumber('abc123sd45'); // '12345'
diff --git a/docs/docs/utils/string/removeSpecialCharacters.md b/docs/docs/utils/string/removeSpecialCharacters.md
index fb7ef2234..099a8c83b 100644
--- a/docs/docs/utils/string/removeSpecialCharacters.md
+++ b/docs/docs/utils/string/removeSpecialCharacters.md
@@ -4,13 +4,16 @@
+## Code
+[🔗 실제 구현 코드 확인](https://github.com/modern-agile-team/modern-kit/blob/main/packages/utils/src/string/removeSpecialCharacters/index.ts)
+
## Interface
-```tsx
+```ts title="typescript"
const removeSpecialCharacters: (value: string) => string
```
## Usage
-```ts
+```ts title="typescript"
import { removeSpecialCharacters } from '@modern-kit/utils';
const str = removeSpecialCharacters('H@#!ello, @Wo!@!&@rld!'); // Hello World
diff --git a/docs/docs/utils/string/repeatCharacters.md b/docs/docs/utils/string/repeatCharacters.md
index 7f184d40b..4532525c4 100644
--- a/docs/docs/utils/string/repeatCharacters.md
+++ b/docs/docs/utils/string/repeatCharacters.md
@@ -4,13 +4,16 @@
+## Code
+[🔗 실제 구현 코드 확인](https://github.com/modern-agile-team/modern-kit/blob/main/packages/utils/src/string/repeatCharacters/index.ts)
+
## Interface
-```tsx
+```ts title="typescript"
const repeatCharacters: (value: string, repeatCount: number) => string
```
## Usage
-```ts
+```ts title="typescript"
import { repeatCharacters } from '@modern-kit/utils';
const str1 = 'A!B@C';
diff --git a/docs/docs/utils/validator/hasProperty.md b/docs/docs/utils/validator/hasProperty.md
index 2051b274c..9ada4f470 100644
--- a/docs/docs/utils/validator/hasProperty.md
+++ b/docs/docs/utils/validator/hasProperty.md
@@ -4,8 +4,11 @@
+## Code
+[🔗 실제 구현 코드 확인](https://github.com/modern-agile-team/modern-kit/blob/main/packages/utils/src/validator/hasProperty/index.ts)
+
## Interface
-```tsx title="typescript"
+```ts title="typescript"
const hasProperty: , K extends PropertyKey>(
obj: T,
key: K
diff --git a/docs/docs/utils/validator/isFuntion.md b/docs/docs/utils/validator/isFuntion.md
index 721937db6..ea4b4812a 100644
--- a/docs/docs/utils/validator/isFuntion.md
+++ b/docs/docs/utils/validator/isFuntion.md
@@ -4,13 +4,16 @@
+## Code
+[🔗 실제 구현 코드 확인](https://github.com/modern-agile-team/modern-kit/blob/main/packages/utils/src/validator/isFunction/index.ts)
+
## Interface
-```tsx title="typescript"
+```ts title="typescript"
const isFunction: (arg: unknown) => arg is Function
```
## Usage
-```ts
+```ts title="typescript"
import { isFunction } from '@modern-kit/utils';
function example() {}
diff --git a/docs/docs/utils/validator/isNotNullish.md b/docs/docs/utils/validator/isNotNullish.md
index 83803013f..4f2e3a6bf 100644
--- a/docs/docs/utils/validator/isNotNullish.md
+++ b/docs/docs/utils/validator/isNotNullish.md
@@ -4,13 +4,16 @@
+## Code
+[🔗 실제 구현 코드 확인](https://github.com/modern-agile-team/modern-kit/blob/main/packages/utils/src/validator/isNotNullish/index.ts)
+
## Interface
-```tsx title="typescript"
+```ts title="typescript"
const isNotNullish: (val: T | null | undefined) => val is T
```
## Usage
-```ts
+```ts title="typescript"
import { isNotNullish } from '@modern-kit/utils';
isNotNullish(1); // true
diff --git a/docs/docs/utils/validator/isNullish.md b/docs/docs/utils/validator/isNullish.md
index 8e8e05d9f..a2b79f55f 100644
--- a/docs/docs/utils/validator/isNullish.md
+++ b/docs/docs/utils/validator/isNullish.md
@@ -4,13 +4,16 @@
+## Code
+[🔗 실제 구현 코드 확인](https://github.com/modern-agile-team/modern-kit/blob/main/packages/utils/src/validator/isNullish/index.ts)
+
## Interface
-```tsx title="typescript"
+```ts title="typescript"
const isNullish: (val: T | null | undefined) => val is null | undefined
```
## Usage
-```ts
+```ts title="typescript"
import { isNullish } from '@modern-kit/utils';
isNullish(undefined); // true
diff --git a/docs/docs/utils/validator/isNumber.md b/docs/docs/utils/validator/isNumber.md
index 8e62c3159..ef39156f7 100644
--- a/docs/docs/utils/validator/isNumber.md
+++ b/docs/docs/utils/validator/isNumber.md
@@ -4,13 +4,16 @@
+## Code
+[🔗 실제 구현 코드 확인](https://github.com/modern-agile-team/modern-kit/blob/main/packages/utils/src/validator/isNumber/index.ts)
+
## Interface
-```tsx title="typescript"
+```ts title="typescript"
const isNumber: (arg: unknown) => arg is number
```
## Usage
-```ts
+```ts title="typescript"
import { isNumber } from '@modern-kit/utils';
diff --git a/docs/docs/utils/validator/isPromise.md b/docs/docs/utils/validator/isPromise.md
index 7f21737e4..40d2eee12 100644
--- a/docs/docs/utils/validator/isPromise.md
+++ b/docs/docs/utils/validator/isPromise.md
@@ -4,13 +4,16 @@
+## Code
+[🔗 실제 구현 코드 확인](https://github.com/modern-agile-team/modern-kit/blob/main/packages/utils/src/validator/isPromise/index.ts)
+
## Interface
-```tsx title="typescript"
+```ts title="typescript"
const isPromise: (value: any) => value is Promise
```
## Usage
-```ts
+```ts title="typescript"
import { isPromise } from '@modern-kit/utils';
isPromise(Promise.resolve()); // true
diff --git a/docs/docs/utils/validator/isValidEmail.md b/docs/docs/utils/validator/isValidEmail.md
index 84153d400..87b596d91 100644
--- a/docs/docs/utils/validator/isValidEmail.md
+++ b/docs/docs/utils/validator/isValidEmail.md
@@ -8,13 +8,16 @@
+## Code
+[🔗 실제 구현 코드 확인](https://github.com/modern-agile-team/modern-kit/blob/main/packages/utils/src/validator/isValidEmail/index.ts)
+
## Interface
-```tsx
+```ts title="typescript"
const isValidEmail: (email: string) => boolean
```
## Usage
-```ts
+```ts title="typescript"
import { isValidEmail } from '@modern-kit/utils';
const isEmail1 = isValidEmail('example@email.com'); // true
diff --git a/docs/docs/utils/validator/isValidPhoneNumberFormat.md b/docs/docs/utils/validator/isValidPhoneNumberFormat.md
index 51273de54..de069c408 100644
--- a/docs/docs/utils/validator/isValidPhoneNumberFormat.md
+++ b/docs/docs/utils/validator/isValidPhoneNumberFormat.md
@@ -12,13 +12,16 @@
+## Code
+[🔗 실제 구현 코드 확인](https://github.com/modern-agile-team/modern-kit/blob/main/packages/utils/src/validator/isValidPhoneNumberFormat/index.ts)
+
## Interface
-```tsx
+```ts title="typescript"
const isValidPhoneNumberFormat: (value: string) => boolean
```
## Usage
-```ts
+```ts title="typescript"
import { isValidPhoneNumberFormat, formatPhoneNumber } from '@modern-kit/utils';
const isPhoneNumberFormat1 = isValidPhoneNumberFormat('010-1234-1234'); // true