<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
</head>
<body>
<script>
const _getExFilename = (filename) => {
// 补全代码
let index = filename.lastIndexOf('.')
return filename.slice(0,index) && index !== -1 ? filename.slice(index) : ''
}
</script>
</body>
</html>
<html lang="en">
<head>
<meta charset="UTF-8">
</head>
<body>
<script>
const _getExFilename = (filename) => {
// 补全代码
let index = filename.lastIndexOf('.')
return filename.slice(0,index) && index !== -1 ? filename.slice(index) : ''
}
</script>
</body>
</html>