Skip to content

bun create astro 로 새 Astro 앱을 초기화하세요. create-astro 패키지는 bunx 를 사용하는지 감지하고 자동으로 bun 을 사용하여 종속성을 설치합니다.

sh
bun create astro
txt
╭─────╮  Houston:
│ ◠ ◡ ◠  We're glad to have you on board.
╰─────╯

 astro   v3.1.4 Launch sequence initiated.

  dir   Where should we create your new project?
        ./fumbling-field

  tmpl   How would you like to start your new project?
         Use blog template
      ✔  Template copied

  deps   Install dependencies?
         Yes
      ✔  Dependencies installed

    ts   Do you plan to write TypeScript?
         Yes

   use   How strict should TypeScript be?
         Strict
      ✔  TypeScript customized

   git   Initialize a new git repository?
         Yes
      ✔  Git initialized

  next   Liftoff confirmed. Explore your project!

         Enter your project directory using cd ./fumbling-field
         Run `bun run dev` to start the dev server. CTRL+C to stop.
         Add frameworks like react or tailwind using astro add.

         Stuck? Join us at https://astro.build/chat

╭─────╮  Houston:
│ ◠ ◡ ◠  Good luck out there, astronaut! 🚀
╰─────╯

bunx 로 개발 서버를 시작하세요.

기본적으로 Bun 은 Node.js 로 개발 서버를 실행합니다. 대신 Bun 런타임을 사용하려면 --bun 플래그를 사용하세요.

sh
bunx --bun astro dev
txt
  🚀  astro  v3.1.4 started in 200ms

  ┃ Local    http://localhost:4321/
  ┃ Network  use --host to expose

결과를 보려면 브라우저에서 http://localhost:4321 을 여세요. Astro 는 소스 파일을 편집할 때 앱을 핫 리로딩합니다.


전체 문서는 Astro 문서 를 참조하세요.

Bun by www.bunjs.com.cn 편집