mirror of
https://hubproxy.babadafafafafa.cn/https://github.com/lyswhut/lx-music-desktop.git
synced 2026-09-20 08:04:00 +08:00
移除 babel
This commit is contained in:
26
.babelrc
26
.babelrc
@@ -1,26 +0,0 @@
|
|||||||
{
|
|
||||||
"presets": [
|
|
||||||
"@babel/preset-typescript",
|
|
||||||
[
|
|
||||||
"@babel/preset-env",
|
|
||||||
{
|
|
||||||
"corejs": "3",
|
|
||||||
"useBuiltIns": "usage"
|
|
||||||
}
|
|
||||||
]
|
|
||||||
// [
|
|
||||||
// "minify",
|
|
||||||
// {
|
|
||||||
// "builtIns": false,
|
|
||||||
// "evaluate": false,
|
|
||||||
// "mangle": false
|
|
||||||
// }
|
|
||||||
// ]
|
|
||||||
],
|
|
||||||
"plugins": [
|
|
||||||
"@babel/plugin-syntax-dynamic-import",
|
|
||||||
"@babel/plugin-transform-modules-umd",
|
|
||||||
"@babel/plugin-transform-runtime",
|
|
||||||
"@babel/plugin-transform-class-properties"
|
|
||||||
]
|
|
||||||
}
|
|
||||||
@@ -55,7 +55,6 @@ const vueRule = {
|
|||||||
exports.base = {
|
exports.base = {
|
||||||
extends: ['standard'],
|
extends: ['standard'],
|
||||||
rules: baseRule,
|
rules: baseRule,
|
||||||
parser: '@babel/eslint-parser',
|
|
||||||
}
|
}
|
||||||
|
|
||||||
exports.html = {
|
exports.html = {
|
||||||
|
|||||||
@@ -19,15 +19,6 @@ module.exports = merge(baseConfig, {
|
|||||||
externals: [
|
externals: [
|
||||||
// ...Object.keys(dependencies || {}).filter(d => !whiteListedModules.includes(d)),
|
// ...Object.keys(dependencies || {}).filter(d => !whiteListedModules.includes(d)),
|
||||||
],
|
],
|
||||||
module: {
|
|
||||||
rules: [
|
|
||||||
{
|
|
||||||
test: /\.js$/,
|
|
||||||
loader: 'babel-loader',
|
|
||||||
exclude: /node_modules/,
|
|
||||||
},
|
|
||||||
],
|
|
||||||
},
|
|
||||||
plugins: [
|
plugins: [
|
||||||
new webpack.DefinePlugin({
|
new webpack.DefinePlugin({
|
||||||
'process.env': {
|
'process.env': {
|
||||||
|
|||||||
@@ -18,15 +18,6 @@ module.exports = merge(baseConfig, {
|
|||||||
externals: [
|
externals: [
|
||||||
// ...Object.keys(dependencies || {}).filter(d => !whiteListedModules.includes(d)),
|
// ...Object.keys(dependencies || {}).filter(d => !whiteListedModules.includes(d)),
|
||||||
],
|
],
|
||||||
module: {
|
|
||||||
rules: [
|
|
||||||
{
|
|
||||||
test: /\.js$/,
|
|
||||||
loader: 'babel-loader',
|
|
||||||
exclude: /node_modules/,
|
|
||||||
},
|
|
||||||
],
|
|
||||||
},
|
|
||||||
plugins: [
|
plugins: [
|
||||||
new webpack.DefinePlugin({
|
new webpack.DefinePlugin({
|
||||||
'process.env': {
|
'process.env': {
|
||||||
|
|||||||
@@ -39,15 +39,6 @@ module.exports = merge(baseConfig, {
|
|||||||
externals: [
|
externals: [
|
||||||
// ...Object.keys(dependencies || {}).filter(d => !whiteListedModules.includes(d)),
|
// ...Object.keys(dependencies || {}).filter(d => !whiteListedModules.includes(d)),
|
||||||
],
|
],
|
||||||
module: {
|
|
||||||
rules: [
|
|
||||||
{
|
|
||||||
test: /\.js$/,
|
|
||||||
loader: 'babel-loader',
|
|
||||||
exclude: /node_modules/,
|
|
||||||
},
|
|
||||||
],
|
|
||||||
},
|
|
||||||
plugins: [
|
plugins: [
|
||||||
new CopyWebpackPlugin({
|
new CopyWebpackPlugin({
|
||||||
patterns: [
|
patterns: [
|
||||||
|
|||||||
@@ -1,12 +1,12 @@
|
|||||||
{
|
{
|
||||||
"compilerOptions": {
|
"compilerOptions": {
|
||||||
"baseUrl": "./",
|
"rootDir": "./",
|
||||||
"paths": {
|
"paths": {
|
||||||
"@main/*": ["src/main/*"],
|
"@main/*": ["./src/main/*"],
|
||||||
"@renderer/*": ["src/renderer/*"],
|
"@renderer/*": ["./src/renderer/*"],
|
||||||
"@lyric/*": ["src/renderer-lyric/*"],
|
"@lyric/*": ["./src/renderer-lyric/*"],
|
||||||
"@static/*": ["src/static/*"],
|
"@static/*": ["./src/static/*"],
|
||||||
"@common/*": ["src/common/*"],
|
"@common/*": ["./src/common/*"],
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"vueCompilerOptions": {
|
"vueCompilerOptions": {
|
||||||
|
|||||||
1878
package-lock.json
generated
1878
package-lock.json
generated
File diff suppressed because it is too large
Load Diff
10
package.json
10
package.json
@@ -107,15 +107,6 @@
|
|||||||
},
|
},
|
||||||
"homepage": "https://github.com/lyswhut/lx-music-desktop#readme",
|
"homepage": "https://github.com/lyswhut/lx-music-desktop#readme",
|
||||||
"devDependencies": {
|
"devDependencies": {
|
||||||
"@babel/core": "^7.29.0",
|
|
||||||
"@babel/eslint-parser": "^7.28.6",
|
|
||||||
"@babel/plugin-syntax-dynamic-import": "^7.8.3",
|
|
||||||
"@babel/plugin-transform-class-properties": "^7.28.6",
|
|
||||||
"@babel/plugin-transform-modules-umd": "^7.27.1",
|
|
||||||
"@babel/plugin-transform-runtime": "^7.29.0",
|
|
||||||
"@babel/preset-env": "^7.29.2",
|
|
||||||
"@babel/preset-typescript": "^7.28.5",
|
|
||||||
"@babel/runtime": "^7.29.2",
|
|
||||||
"@tsconfig/recommended": "^1.0.13",
|
"@tsconfig/recommended": "^1.0.13",
|
||||||
"@types/better-sqlite3": "^7.6.13",
|
"@types/better-sqlite3": "^7.6.13",
|
||||||
"@types/needle": "^3.3.0",
|
"@types/needle": "^3.3.0",
|
||||||
@@ -123,7 +114,6 @@
|
|||||||
"@types/tunnel": "^0.0.7",
|
"@types/tunnel": "^0.0.7",
|
||||||
"@types/ws": "8.5.4",
|
"@types/ws": "8.5.4",
|
||||||
"@vue/language-plugin-pug": "^3.2.6",
|
"@vue/language-plugin-pug": "^3.2.6",
|
||||||
"babel-loader": "^10.1.1",
|
|
||||||
"browserslist": "^4.28.1",
|
"browserslist": "^4.28.1",
|
||||||
"chalk": "^4.1.2",
|
"chalk": "^4.1.2",
|
||||||
"changelog-parser": "^3.0.1",
|
"changelog-parser": "^3.0.1",
|
||||||
|
|||||||
@@ -5,7 +5,7 @@
|
|||||||
"./types"
|
"./types"
|
||||||
],
|
],
|
||||||
"paths": { /* Specify a set of entries that re-map imports to additional lookup locations. */
|
"paths": { /* Specify a set of entries that re-map imports to additional lookup locations. */
|
||||||
"@common/*": ["common/*"],
|
"@common/*": ["./*"],
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -5,10 +5,10 @@
|
|||||||
"./types"
|
"./types"
|
||||||
],
|
],
|
||||||
"paths": { /* Specify a set of entries that re-map imports to additional lookup locations. */
|
"paths": { /* Specify a set of entries that re-map imports to additional lookup locations. */
|
||||||
"@common/*": ["common/*"],
|
"@common/*": ["../common/*"],
|
||||||
"@main/*": ["main/*"],
|
"@main/*": ["../main/*"],
|
||||||
"@static/*": ["static/*"],
|
"@static/*": ["../static/*"],
|
||||||
"@/*": ["./*"],
|
"@/*": ["../*"],
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -3,11 +3,11 @@
|
|||||||
"compilerOptions": {
|
"compilerOptions": {
|
||||||
"isolatedModules": true,
|
"isolatedModules": true,
|
||||||
"paths": { /* Specify a set of entries that re-map imports to additional lookup locations. */
|
"paths": { /* Specify a set of entries that re-map imports to additional lookup locations. */
|
||||||
"@common/*": ["common/*"],
|
"@common/*": ["../common/*"],
|
||||||
// "@renderer/*": ["renderer/*"],
|
// "@renderer/*": ["renderer/*"],
|
||||||
"@lyric/*": ["renderer-lyric/*"],
|
"@lyric/*": ["../renderer-lyric/*"],
|
||||||
"@static/*": ["static/*"],
|
"@static/*": ["../static/*"],
|
||||||
"@root/*": ["./*"],
|
"@root/*": ["../*"],
|
||||||
},
|
},
|
||||||
"typeRoots": [ /* Specify multiple folders that act like './node_modules/@types'. */
|
"typeRoots": [ /* Specify multiple folders that act like './node_modules/@types'. */
|
||||||
"./types"
|
"./types"
|
||||||
|
|||||||
@@ -3,11 +3,11 @@
|
|||||||
"compilerOptions": {
|
"compilerOptions": {
|
||||||
"isolatedModules": true,
|
"isolatedModules": true,
|
||||||
"paths": { /* Specify a set of entries that re-map imports to additional lookup locations. */
|
"paths": { /* Specify a set of entries that re-map imports to additional lookup locations. */
|
||||||
"@common/*": ["common/*"],
|
"@common/*": ["../common/*"],
|
||||||
"@renderer/*": ["renderer/*"],
|
"@renderer/*": ["../renderer/*"],
|
||||||
// "@lyric/*": ["renderer-lyric/*"],
|
// "@lyric/*": ["../renderer-lyric/*"],
|
||||||
"@static/*": ["static/*"],
|
"@static/*": ["../static/*"],
|
||||||
"@root/*": ["./*"],
|
"@root/*": ["../*"],
|
||||||
},
|
},
|
||||||
"typeRoots": [ /* Specify multiple folders that act like './node_modules/@types'. */
|
"typeRoots": [ /* Specify multiple folders that act like './node_modules/@types'. */
|
||||||
"./types"
|
"./types"
|
||||||
|
|||||||
@@ -1,7 +1,7 @@
|
|||||||
import { checkPath, joinPath, extname, basename, readFile, getFileStats } from '@common/utils/nodejs'
|
import { checkPath, joinPath, extname, basename, readFile, getFileStats } from '@common/utils/nodejs'
|
||||||
import { formatPlayTime } from '@common/utils/common'
|
import { formatPlayTime } from '@common/utils/common'
|
||||||
import type { IComment } from 'music-metadata/lib/type'
|
|
||||||
import { decodeKrc } from '@common/utils/lyricUtils/kg'
|
import { decodeKrc } from '@common/utils/lyricUtils/kg'
|
||||||
|
import { type IAudioMetadata } from 'music-metadata'
|
||||||
|
|
||||||
export const checkDownloadFileAvailable = async(musicInfo: LX.Download.ListItem, savePath: string): Promise<boolean> => {
|
export const checkDownloadFileAvailable = async(musicInfo: LX.Download.ListItem, savePath: string): Promise<boolean> => {
|
||||||
return musicInfo.isComplate && !/\.ape$/.test(musicInfo.metadata.fileName) &&
|
return musicInfo.isComplate && !/\.ape$/.test(musicInfo.metadata.fileName) &&
|
||||||
@@ -164,6 +164,7 @@ export const getLocalMusicFilePic = async(path: string) => {
|
|||||||
// return lyricInfo
|
// return lyricInfo
|
||||||
// }
|
// }
|
||||||
|
|
||||||
|
type IComment = NonNullable<IAudioMetadata['common']['comment']> extends Array<infer U> ? U : never
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 获取歌曲文件歌词
|
* 获取歌曲文件歌词
|
||||||
|
|||||||
@@ -5,10 +5,10 @@
|
|||||||
"target": "ESNext",
|
"target": "ESNext",
|
||||||
"allowJs": true,
|
"allowJs": true,
|
||||||
"module": "ESNext",
|
"module": "ESNext",
|
||||||
"moduleResolution": "Node",
|
"moduleResolution": "bundler",
|
||||||
"resolveJsonModule": true,
|
"resolveJsonModule": true,
|
||||||
|
"rootDir": "./",
|
||||||
"outDir": "./dist",
|
"outDir": "./dist",
|
||||||
"baseUrl": "./src", /* Specify the base directory to resolve non-relative module names. */
|
|
||||||
// "paths": { /* Specify a set of entries that re-map imports to additional lookup locations. */
|
// "paths": { /* Specify a set of entries that re-map imports to additional lookup locations. */
|
||||||
// "@common/*": ["common/*"],
|
// "@common/*": ["common/*"],
|
||||||
// "@renderer/*": ["renderer/*"],
|
// "@renderer/*": ["renderer/*"],
|
||||||
|
|||||||
Reference in New Issue
Block a user