当前位置:网站首页>JS delete substring in string
JS delete substring in string
2022-07-02 17:00:00 【spring-java】
const removeString = (string, separator) => {
// We split the string without delimiters
const separatedArray = string.split(separator);
// We use an empty string to splittedArray Join in
const separatedString = separatedArray.join("");
return separatedString;
}
const str = removeString('this-is-a-sting', '-');
console.log(str);
边栏推荐
- 大廠面試總結大全
- LeetCode 3. 无重复字符的最长子串
- P6774 [NOI2020] 时代的眼泪(分块)
- [North Asia data recovery] data recovery case of raid crash caused by hard disk disconnection during data synchronization of hot spare disk of RAID5 disk array
- Learning Weekly - total issue 60 - 25th week of 2022
- LeetCode 2. Add two numbers
- 有赞和腾讯云、阿里云一同摘得“中国企业云科技服务商50强”[通俗易懂]
- PhD battle-11 preview | review and prospect backdoor attack and defense of neural network
- MySQL port
- LeetCode 6. Zigzag transformation (n-shaped transformation)
猜你喜欢

PWM controlled steering gear

PhD Debate-11 预告 | 回顾与展望神经网络的后门攻击与防御

Leetcode1380: lucky numbers in matrix

小鹏P7雨天出事故安全气囊没有弹出 官方回应:撞击力度未达到弹出要求

上传代码到远程仓库报错error: remote origin already exists.

Configure ARP table entry restrictions and port security based on the interface (restrict users' private access to fool switches or illegal host access)

大厂面试总结大全

电脑自带软件使图片底色变为透明(抠图白底)
![[cloud native] briefly talk about the understanding of flume, a massive data collection component](/img/2d/8c4769e97fb84e98eafb7069551341.png)
[cloud native] briefly talk about the understanding of flume, a massive data collection component

Cell: Tsinghua Chenggong group revealed an odor of skin flora. Volatiles promote flavivirus to infect the host and attract mosquitoes
随机推荐
What will you do after digital IC Verification?
你想要的宏基因组-微生物组知识全在这(2022.7)
C语言中sprintf()函数的用法
Written by unity Jason
AcWing 300. Task arrangement
深度学习图像数据自动标注[通俗易懂]
Global and Chinese markets for slotting milling machines 2022-2028: Research Report on technology, participants, trends, market size and share
Interview summary of large factories
Usage of sprintf() function in C language
LeetCode 5. Longest Palindromic Substring
Leetcode1380: lucky numbers in matrix
渗透工具-内网权限维持-Cobalt strike
2322. 从树中删除边的最小分数(异或和&模拟)
Lampe respiratoire PWM
Easy language ABCD sort
Global and Chinese market of jacquard looms 2022-2028: Research Report on technology, participants, trends, market size and share
Learning Weekly - total issue 60 - 25th week of 2022
How to choose the right kubernetes storage plug-in? (09)
LeetCode 6. Z 字形变换 (N字形变换)
Serial port controls steering gear rotation