# DAY18 - JavaScript 13. 宣告字串流程 ### 簡易,組字串流程 - 宣告變數為字串的方法: ``` // 變數賦予值,要加上''; let a = '這是一個字串內容'; ``` - ''代表這個變數是字串 - string 型別,要確認型別的話,也可以使用 `typeof` 查詢 ``` console.log(typeof a); // 此時,console 會帶出: string ``` - 在呼叫一次 a: ``` console.log(a); // 這是一個字串內容 ``` ###### tags: `Re:0 前端工程師之路 - JavaScript 字串 篇章`
×
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