-
Notifications
You must be signed in to change notification settings - Fork 97
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
2 changed files
with
75 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,38 @@ | ||
|
||
--- | ||
title: assemble | ||
--- | ||
|
||
import { Sandpack } from '@/components/Sandpack'; | ||
|
||
|
||
# assemble | ||
|
||
Combine the Korean sentences and characters in the array received as input according to Korean language rules. | ||
|
||
```typescript | ||
function assemble( | ||
// An array containing Korean characters and sentences. | ||
words: string[] | ||
): string | ||
``` | ||
|
||
|
||
|
||
## Demo | ||
|
||
<br /> | ||
|
||
<Sandpack> | ||
|
||
```ts index.ts | ||
import { assemble } from 'es-hangul'; | ||
console.log(assemble(['아버지가', ' ', '방ㅇ', 'ㅔ ', '들ㅇ', 'ㅓ갑니다'])) | ||
console.log(assemble(['아버지가', ' ', '방에 ', '들어갑니다'])) | ||
console.log(assemble(['ㅇ', 'ㅏ', 'ㅂ', 'ㅓ', 'ㅈ', 'ㅣ'])) | ||
``` | ||
|
||
</Sandpack> | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,37 @@ | ||
--- | ||
title: assemble | ||
--- | ||
|
||
import { Sandpack } from '@/components/Sandpack'; | ||
|
||
|
||
# assemble | ||
|
||
인자로 받은 배열에 담긴 한글 문장과 문자를 한글 규칙에 맞게 합성합니다. | ||
|
||
```typescript | ||
function assemble( | ||
// 한글 문자와 문장을 담고 있는 배열 | ||
words: string[] | ||
): string | ||
``` | ||
|
||
|
||
|
||
## 사용해보기 | ||
|
||
<br /> | ||
|
||
<Sandpack> | ||
|
||
```ts index.ts | ||
import { assemble } from 'es-hangul'; | ||
console.log(assemble(['아버지가', ' ', '방ㅇ', 'ㅔ ', '들ㅇ', 'ㅓ갑니다'])) | ||
console.log(assemble(['아버지가', ' ', '방에 ', '들어갑니다'])) | ||
console.log(assemble(['ㅇ', 'ㅏ', 'ㅂ', 'ㅓ', 'ㅈ', 'ㅣ'])) | ||
``` | ||
|
||
</Sandpack> | ||
|