그냥 JavaScript입니다. 말투만 한남입니다. .hn으로 쓰고 JS로 바꿔 브라우저와 Node에서 실행합니다.
Translation pending
Developer toolsTypeScript · MDXGitHub @keemtjOnlineOwner unconfirmed
Have you tried it? One tap is enough. No sign-in needed.
Owners of public repositories under a personal GitHub account can sign in to verify ownership and manage the introduction themselves. No administrator approval is needed.
Sign in, generate a verification file, and commit it to this repository’s default branch within 30 minutes. Files on other branches or forks do not count. Then check the file below to manage the project without administrator approval. Keep the file to retain your access.
If needed, you will go to sign-in. After signing in, return here and press your chosen verification button again.
Run /nomorevibe verify in your project folder to verify ownership and manage the introduction yourself.
Verify in one minuteAsk about other verification options
The maker's introduction consists of the line above. Read the repository README for more details. Repository README ↗
Loading the full README.
Read the full README ↗한남랭(hannam-lang)은 새 언어가 아니라 JavaScript를 한남 말투로 쓰는 방법입니다. .hn 파일에 if 대신 예?, console.log 대신 무슨 발언이세요?처럼 쓰면 컴파일러가 JavaScript로 바꿉니다. 바뀌는 것은 문장 맨 앞의 키워드뿐이고, 나머지 문법과 DOM, fetch, Node API, npm 패키지는 JS 그대로 씁니다. 출력은 ES 모듈이라 브라우저, Node, Bun에서 실행됩니다.
티~원 불러오기() {
아! 줴줴이야~ [
{ 내용: "우유 사기", 완료: true },
{ 내용: "README 쓰기", 완료: false },
]
}
요이~ 할일 티~원! 불러오기() {
예? 할일.완료 {
아뇨
}
무슨 발언이세요? `□ ${할일.내용}`
}
async function 불러오기() {
return [
{ 내용: "우유 사기", 완료: true },
{ 내용: "README 쓰기", 완료: false },
]
}
for (const 할일 of await 불러오기()) {
if (할일.완료) {
continue
}
console.log(`□ ${할일.내용}`)
}
| 한남랭 | JavaScript |
|---|---|
엄 / 엄. / 엄.. / 엄... | var / let / const / // 주석 |
예? / 예?? / 예??? | if / else if / switch |
아뇨아뇨아뇨아뇨 | else, default |
요이~ / 요이이이~ | for...of·범위 반복 / while |
요히~ | for...in |
줴줴이야 / 아뇨 | break / continue |
아! 줴줴이야~ / 아... 줴줴이야... | return / throw |
티-원 / 티~원 / 티~원! | function / async function / await |
진~지? / 지~랄 | try / catch |
오호호호호~ / 오호호호홋~ | class / class extends |
무슨 발언이세요? 값 / 예? 무슨 발언이세요?(질문) | console.log / confirm |
Node 20.16 이상이 필요합니다.
npm i -D hannam-lang
npx hannam todo.hn # 바로 실행
npx hnc todo.hn # todo.js로 컴파일
hannam은 .hn을 바로 실행하는 실행기이고, hnc(hannam compiler)는 .js 파일을 만드는 컴파일러입니다. pnpm, yarn, bun으로 설치하는 방법은 설치 문서에 있습니다.
| 패키지 | 하는 일 |
|---|---|
hannam-lang | 실행기 hannam, 컴파일러 hnc, Node 로더 훅, Bun 플러그인 |
@hannam-lang/vite-plugin | Vite에서 .hn을 바로 import합니다 |
@hannam-lang/core | 변환기 API(compile). 빌드 도구를 직접 만들 때 씁니다 |
| VS Code 확장 | 문법 하이라이팅, 스니펫, 컴파일 에러 표시. 저장소에서 .vsix로 설치합니다 |
.hn 원본을 가리킵니다.자세한 내용은 컴파일러 구조에 있습니다.
.hn으로 짠 예제(examples/todo)pnpm install
pnpm build
pnpm test
개발 환경, 커밋 규칙, 새 키워드를 제안하는 기준은 CONTRIBUTING.md에 있습니다.
패키지에 영향을 주는 변경에는 changeset을 추가합니다.
pnpm changeset
main에 병합되면 버전 PR이 만들어지거나 갱신됩니다. 버전 PR을 병합하면 npm 패키지가 배포됩니다. 처음 한 번 필요한 저장소 설정은 RELEASING.md에 있습니다.