• 注册
  • 查看作者
  • 接上

    ### String

    常用属性length

    常用函数
    1. charAt()

    获取指定下标的字符串

    2. concat()

    连接字符串

    3. indexOf()

    获取某个字符串在当前字符串的第一次索引

    4. lastIndexOf()

    获取某个字符串在当前字符串的最后一次索引

    5. replace()

    替换,只能替换第一个

    6. split()

    拆分字符串

    7. substr(startIndex,length)

    截取字符串

    8. substring(startIndex,endInex)

    截取字符串

    9. toLowerCase()

    转小写

    10. toUpperCase()

    转大写

  • 7
  • 0
  • 0
  • 2.1k
  • 请登录之后再进行评论

    登录
    单栏布局 侧栏位置:
    关闭窗口
    下载海报