[簡介連結](https://bootstrap5.hexschool.com/docs/5.1/getting-started/introduction/) ## CDN 引入 ### CSS `<link href="https://cdn.jsdelivr.net/npm/bootstrap@5.1.1/dist/css/bootstrap.min.css" rel="stylesheet" integrity="sha384-F3w7mX95PdgyTmZZMECAngseQB83DfGTowi0iMjiWaeVhAn4FJkqJByhZMI3AhiU" crossorigin="anonymous"> ` ### JS `<script src="https://cdn.jsdelivr.net/npm/bootstrap@5.1.1/dist/js/bootstrap.bundle.min.js" integrity="sha384-/bQdsTh/da6pkI1MST/rWKFNjaCP5gBSY4sEBT38Q/9RBh9AH40zEOg7Hlq2THRZ" crossorigin="anonymous"></script>` ## 初學者範本 [範本連結](https://bootstrap5.hexschool.com/docs/5.1/getting-started/introduction/#starter-template) 也可以直接使用初學者範本,快速建立環境 ### 範本需要做修改 簡體、繁體、台灣中文和日文等等,字體是不同的,需要依照需求來調整語系代碼 * 語系 lang="en" 改為 lang="zh-TW" (zh-Hant-TW) ## 載入成功測試 在 HTML 貼上按鈕元件,觀察是否套用 bootstrap 樣式,bootstrap 的樣式如下圖。  ## 沒載入 JS Bootstrap 有些功能是需要使用 JS 的,例如:[按鈕切換狀態](https://bootstrap5.hexschool.com/docs/5.1/components/buttons/#toggle-states)。 * 可以貼上切換按鈕狀態的程式碼測試,是否成功載入 JS。 * JS CDN 要放在 body 結尾標籤前面。
×
Sign in
Email
Password
Forgot password
or
By clicking below, you agree to our
terms of service
.
Sign in via Facebook
Sign in via Twitter
Sign in via GitHub
Sign in via Dropbox
Sign in with Wallet
Wallet (
)
Connect another wallet
New to HackMD?
Sign up