mirror of
https://github.com/imdap/ruoyi-plus-vben5.git
synced 2026-04-23 00:38:34 +08:00
revert: "fix: sass-embedded@1.98.0 在 macOS 13 会直接崩 (#7692)"
This commit is contained in:
@@ -26,8 +26,8 @@ The repository uses Monorepo management, and the project structure is as follows
|
|||||||
│ ├── node-utils # Node.js tools
|
│ ├── node-utils # Node.js tools
|
||||||
│ ├── tsconfig # Common tsconfig settings
|
│ ├── tsconfig # Common tsconfig settings
|
||||||
│ └── vite-config # Common Vite configuration
|
│ └── vite-config # Common Vite configuration
|
||||||
├── oxfmt.config.mjs # Oxfmt config entry
|
├── oxfmt.config.ts # Oxfmt config entry
|
||||||
├── oxlint.config.mjs # Oxlint configuration file
|
├── oxlint.config.ts # Oxlint configuration file
|
||||||
├── package.json # Project dependency configuration
|
├── package.json # Project dependency configuration
|
||||||
├── packages # Project packages directory
|
├── packages # Project packages directory
|
||||||
│ ├── @core # Core package
|
│ ├── @core # Core package
|
||||||
|
|||||||
@@ -49,7 +49,7 @@ pnpm oxfmt --check
|
|||||||
|
|
||||||
### Configuration
|
### Configuration
|
||||||
|
|
||||||
The root Oxfmt entry file is `oxfmt.config.mjs`, and its core configuration is located in `internal/lint-configs/oxfmt-config`.
|
The root Oxfmt entry file is `oxfmt.config.ts`, and its core configuration is located in `internal/lint-configs/oxfmt-config`.
|
||||||
|
|
||||||
## Oxlint
|
## Oxlint
|
||||||
|
|
||||||
@@ -64,7 +64,7 @@ pnpm oxlint --fix
|
|||||||
|
|
||||||
### Configuration
|
### Configuration
|
||||||
|
|
||||||
The core Oxlint configuration is located in `internal/lint-configs/oxlint-config`, and the root entry file is `oxlint.config.mjs`.
|
The core Oxlint configuration is located in `internal/lint-configs/oxlint-config`, and the root entry file is `oxlint.config.ts`.
|
||||||
|
|
||||||
## ESLint
|
## ESLint
|
||||||
|
|
||||||
|
|||||||
@@ -26,8 +26,8 @@
|
|||||||
│ ├── node-utils # Node.js 工具
|
│ ├── node-utils # Node.js 工具
|
||||||
│ ├── tsconfig # 通用 tsconfig 配置
|
│ ├── tsconfig # 通用 tsconfig 配置
|
||||||
│ └── vite-config # 通用 Vite 配置
|
│ └── vite-config # 通用 Vite 配置
|
||||||
├── oxfmt.config.mjs # Oxfmt 配置入口
|
├── oxfmt.config.ts # Oxfmt 配置入口
|
||||||
├── oxlint.config.mjs # Oxlint 配置文件
|
├── oxlint.config.ts # Oxlint 配置文件
|
||||||
├── package.json # 项目依赖配置
|
├── package.json # 项目依赖配置
|
||||||
├── packages # 项目包目录
|
├── packages # 项目包目录
|
||||||
│ ├── @core # 核心包
|
│ ├── @core # 核心包
|
||||||
|
|||||||
@@ -49,7 +49,7 @@ pnpm oxfmt --check
|
|||||||
|
|
||||||
### 配置
|
### 配置
|
||||||
|
|
||||||
Oxfmt 的根目录入口文件为 `oxfmt.config.mjs`,其核心配置位于 `internal/lint-configs/oxfmt-config` 目录下,可以根据项目需求进行修改。
|
Oxfmt 的根目录入口文件为 `oxfmt.config.ts`,其核心配置位于 `internal/lint-configs/oxfmt-config` 目录下,可以根据项目需求进行修改。
|
||||||
|
|
||||||
## Oxlint
|
## Oxlint
|
||||||
|
|
||||||
@@ -64,7 +64,7 @@ pnpm oxlint --fix
|
|||||||
|
|
||||||
### 配置
|
### 配置
|
||||||
|
|
||||||
Oxlint 的核心配置位于 `internal/lint-configs/oxlint-config` 目录下,根目录入口文件为 `oxlint.config.mjs`。
|
Oxlint 的核心配置位于 `internal/lint-configs/oxlint-config` 目录下,根目录入口文件为 `oxlint.config.ts`。
|
||||||
|
|
||||||
## ESLint
|
## ESLint
|
||||||
|
|
||||||
|
|||||||
@@ -1,18 +1,18 @@
|
|||||||
import type { CSSOptions, UserConfig } from "vite";
|
import type { CSSOptions, UserConfig } from 'vite';
|
||||||
|
|
||||||
import type { DefineApplicationOptions } from "../typing";
|
import type { DefineApplicationOptions } from '../typing';
|
||||||
|
|
||||||
import path, { relative } from "node:path";
|
import path, { relative } from 'node:path';
|
||||||
|
|
||||||
import { findMonorepoRoot } from "@vben/node-utils";
|
import { findMonorepoRoot } from '@vben/node-utils';
|
||||||
|
|
||||||
import { NodePackageImporter } from "sass";
|
import { NodePackageImporter } from 'sass-embedded';
|
||||||
import { defineConfig, loadEnv, mergeConfig } from "vite";
|
import { defineConfig, loadEnv, mergeConfig } from 'vite';
|
||||||
|
|
||||||
import { defaultImportmapOptions, getDefaultPwaOptions } from "../options";
|
import { defaultImportmapOptions, getDefaultPwaOptions } from '../options';
|
||||||
import { loadApplicationPlugins } from "../plugins";
|
import { loadApplicationPlugins } from '../plugins';
|
||||||
import { loadAndConvertEnv } from "../utils/env";
|
import { loadAndConvertEnv } from '../utils/env';
|
||||||
import { getCommonConfig } from "./common";
|
import { getCommonConfig } from './common';
|
||||||
|
|
||||||
function defineApplicationConfig(userConfigPromise?: DefineApplicationOptions) {
|
function defineApplicationConfig(userConfigPromise?: DefineApplicationOptions) {
|
||||||
return defineConfig(async (config) => {
|
return defineConfig(async (config) => {
|
||||||
@@ -21,14 +21,14 @@ function defineApplicationConfig(userConfigPromise?: DefineApplicationOptions) {
|
|||||||
const { command, mode } = config;
|
const { command, mode } = config;
|
||||||
const { application = {}, vite = {} } = options || {};
|
const { application = {}, vite = {} } = options || {};
|
||||||
const root = process.cwd();
|
const root = process.cwd();
|
||||||
const isBuild = command === "build";
|
const isBuild = command === 'build';
|
||||||
const env = loadEnv(mode, root);
|
const env = loadEnv(mode, root);
|
||||||
|
|
||||||
const plugins = await loadApplicationPlugins({
|
const plugins = await loadApplicationPlugins({
|
||||||
archiver: true,
|
archiver: true,
|
||||||
archiverPluginOptions: {},
|
archiverPluginOptions: {},
|
||||||
compress: false,
|
compress: false,
|
||||||
compressTypes: ["brotli", "gzip"],
|
compressTypes: ['brotli', 'gzip'],
|
||||||
devtools: true,
|
devtools: true,
|
||||||
env,
|
env,
|
||||||
extraAppConfig: true,
|
extraAppConfig: true,
|
||||||
@@ -44,7 +44,7 @@ function defineApplicationConfig(userConfigPromise?: DefineApplicationOptions) {
|
|||||||
nitroMockOptions: {},
|
nitroMockOptions: {},
|
||||||
print: !isBuild,
|
print: !isBuild,
|
||||||
printInfoMap: {
|
printInfoMap: {
|
||||||
"Vben Admin Docs": "https://doc.vben.pro",
|
'Vben Admin Docs': 'https://doc.vben.pro',
|
||||||
},
|
},
|
||||||
pwa: true,
|
pwa: true,
|
||||||
pwaOptions: getDefaultPwaOptions(appTitle),
|
pwaOptions: getDefaultPwaOptions(appTitle),
|
||||||
@@ -60,9 +60,9 @@ function defineApplicationConfig(userConfigPromise?: DefineApplicationOptions) {
|
|||||||
build: {
|
build: {
|
||||||
rolldownOptions: {
|
rolldownOptions: {
|
||||||
output: {
|
output: {
|
||||||
assetFileNames: "[ext]/[name]-[hash].[ext]",
|
assetFileNames: '[ext]/[name]-[hash].[ext]',
|
||||||
chunkFileNames: "js/[name]-[hash].js",
|
chunkFileNames: 'js/[name]-[hash].js',
|
||||||
entryFileNames: "jse/index-[name]-[hash].js",
|
entryFileNames: 'jse/index-[name]-[hash].js',
|
||||||
minify: isBuild
|
minify: isBuild
|
||||||
? {
|
? {
|
||||||
compress: {
|
compress: {
|
||||||
@@ -72,7 +72,7 @@ function defineApplicationConfig(userConfigPromise?: DefineApplicationOptions) {
|
|||||||
: false,
|
: false,
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
target: "es2015",
|
target: 'es2015',
|
||||||
},
|
},
|
||||||
css: createCssOptions(injectGlobalScss),
|
css: createCssOptions(injectGlobalScss),
|
||||||
plugins,
|
plugins,
|
||||||
@@ -82,15 +82,18 @@ function defineApplicationConfig(userConfigPromise?: DefineApplicationOptions) {
|
|||||||
warmup: {
|
warmup: {
|
||||||
// 预热文件
|
// 预热文件
|
||||||
clientFiles: [
|
clientFiles: [
|
||||||
"./index.html",
|
'./index.html',
|
||||||
"./src/bootstrap.ts",
|
'./src/bootstrap.ts',
|
||||||
"./src/{views,layouts,router,store,api,adapter}/*",
|
'./src/{views,layouts,router,store,api,adapter}/*',
|
||||||
],
|
],
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
};
|
};
|
||||||
|
|
||||||
const mergedCommonConfig = mergeConfig(await getCommonConfig(), applicationConfig);
|
const mergedCommonConfig = mergeConfig(
|
||||||
|
await getCommonConfig(),
|
||||||
|
applicationConfig,
|
||||||
|
);
|
||||||
return mergeConfig(mergedCommonConfig, vite);
|
return mergeConfig(mergedCommonConfig, vite);
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -2,179 +2,179 @@
|
|||||||
"folders": [
|
"folders": [
|
||||||
{
|
{
|
||||||
"name": "@vben/backend-mock",
|
"name": "@vben/backend-mock",
|
||||||
"path": "apps/backend-mock",
|
"path": "apps/backend-mock"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"name": "@vben/web-antd",
|
"name": "@vben/web-antd",
|
||||||
"path": "apps/web-antd",
|
"path": "apps/web-antd"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"name": "@vben/web-antdv-next",
|
"name": "@vben/web-antdv-next",
|
||||||
"path": "apps/web-antdv-next",
|
"path": "apps/web-antdv-next"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"name": "@vben/web-ele",
|
"name": "@vben/web-ele",
|
||||||
"path": "apps/web-ele",
|
"path": "apps/web-ele"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"name": "@vben/web-naive",
|
"name": "@vben/web-naive",
|
||||||
"path": "apps/web-naive",
|
"path": "apps/web-naive"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"name": "@vben/web-tdesign",
|
"name": "@vben/web-tdesign",
|
||||||
"path": "apps/web-tdesign",
|
"path": "apps/web-tdesign"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"name": "@vben/docs",
|
"name": "@vben/docs",
|
||||||
"path": "docs",
|
"path": "docs"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"name": "@vben/commitlint-config",
|
"name": "@vben/commitlint-config",
|
||||||
"path": "internal/lint-configs/commitlint-config",
|
"path": "internal/lint-configs/commitlint-config"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"name": "@vben/eslint-config",
|
"name": "@vben/eslint-config",
|
||||||
"path": "internal/lint-configs/eslint-config",
|
"path": "internal/lint-configs/eslint-config"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"name": "@vben/oxfmt-config",
|
"name": "@vben/oxfmt-config",
|
||||||
"path": "internal/lint-configs/oxfmt-config",
|
"path": "internal/lint-configs/oxfmt-config"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"name": "@vben/oxlint-config",
|
"name": "@vben/oxlint-config",
|
||||||
"path": "internal/lint-configs/oxlint-config",
|
"path": "internal/lint-configs/oxlint-config"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"name": "@vben/stylelint-config",
|
"name": "@vben/stylelint-config",
|
||||||
"path": "internal/lint-configs/stylelint-config",
|
"path": "internal/lint-configs/stylelint-config"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"name": "@vben/node-utils",
|
"name": "@vben/node-utils",
|
||||||
"path": "internal/node-utils",
|
"path": "internal/node-utils"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"name": "@vben/tsconfig",
|
"name": "@vben/tsconfig",
|
||||||
"path": "internal/tsconfig",
|
"path": "internal/tsconfig"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"name": "@vben/vite-config",
|
"name": "@vben/vite-config",
|
||||||
"path": "internal/vite-config",
|
"path": "internal/vite-config"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"name": "@vben-core/design",
|
"name": "@vben-core/design",
|
||||||
"path": "packages/@core/base/design",
|
"path": "packages/@core/base/design"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"name": "@vben-core/icons",
|
"name": "@vben-core/icons",
|
||||||
"path": "packages/@core/base/icons",
|
"path": "packages/@core/base/icons"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"name": "@vben-core/shared",
|
"name": "@vben-core/shared",
|
||||||
"path": "packages/@core/base/shared",
|
"path": "packages/@core/base/shared"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"name": "@vben-core/typings",
|
"name": "@vben-core/typings",
|
||||||
"path": "packages/@core/base/typings",
|
"path": "packages/@core/base/typings"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"name": "@vben-core/composables",
|
"name": "@vben-core/composables",
|
||||||
"path": "packages/@core/composables",
|
"path": "packages/@core/composables"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"name": "@vben-core/preferences",
|
"name": "@vben-core/preferences",
|
||||||
"path": "packages/@core/preferences",
|
"path": "packages/@core/preferences"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"name": "@vben-core/form-ui",
|
"name": "@vben-core/form-ui",
|
||||||
"path": "packages/@core/ui-kit/form-ui",
|
"path": "packages/@core/ui-kit/form-ui"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"name": "@vben-core/layout-ui",
|
"name": "@vben-core/layout-ui",
|
||||||
"path": "packages/@core/ui-kit/layout-ui",
|
"path": "packages/@core/ui-kit/layout-ui"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"name": "@vben-core/menu-ui",
|
"name": "@vben-core/menu-ui",
|
||||||
"path": "packages/@core/ui-kit/menu-ui",
|
"path": "packages/@core/ui-kit/menu-ui"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"name": "@vben-core/popup-ui",
|
"name": "@vben-core/popup-ui",
|
||||||
"path": "packages/@core/ui-kit/popup-ui",
|
"path": "packages/@core/ui-kit/popup-ui"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"name": "@vben-core/shadcn-ui",
|
"name": "@vben-core/shadcn-ui",
|
||||||
"path": "packages/@core/ui-kit/shadcn-ui",
|
"path": "packages/@core/ui-kit/shadcn-ui"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"name": "@vben-core/tabs-ui",
|
"name": "@vben-core/tabs-ui",
|
||||||
"path": "packages/@core/ui-kit/tabs-ui",
|
"path": "packages/@core/ui-kit/tabs-ui"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"name": "@vben/constants",
|
"name": "@vben/constants",
|
||||||
"path": "packages/constants",
|
"path": "packages/constants"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"name": "@vben/access",
|
"name": "@vben/access",
|
||||||
"path": "packages/effects/access",
|
"path": "packages/effects/access"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"name": "@vben/common-ui",
|
"name": "@vben/common-ui",
|
||||||
"path": "packages/effects/common-ui",
|
"path": "packages/effects/common-ui"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"name": "@vben/hooks",
|
"name": "@vben/hooks",
|
||||||
"path": "packages/effects/hooks",
|
"path": "packages/effects/hooks"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"name": "@vben/layouts",
|
"name": "@vben/layouts",
|
||||||
"path": "packages/effects/layouts",
|
"path": "packages/effects/layouts"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"name": "@vben/plugins",
|
"name": "@vben/plugins",
|
||||||
"path": "packages/effects/plugins",
|
"path": "packages/effects/plugins"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"name": "@vben/request",
|
"name": "@vben/request",
|
||||||
"path": "packages/effects/request",
|
"path": "packages/effects/request"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"name": "@vben/icons",
|
"name": "@vben/icons",
|
||||||
"path": "packages/icons",
|
"path": "packages/icons"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"name": "@vben/locales",
|
"name": "@vben/locales",
|
||||||
"path": "packages/locales",
|
"path": "packages/locales"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"name": "@vben/preferences",
|
"name": "@vben/preferences",
|
||||||
"path": "packages/preferences",
|
"path": "packages/preferences"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"name": "@vben/stores",
|
"name": "@vben/stores",
|
||||||
"path": "packages/stores",
|
"path": "packages/stores"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"name": "@vben/styles",
|
"name": "@vben/styles",
|
||||||
"path": "packages/styles",
|
"path": "packages/styles"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"name": "@vben/types",
|
"name": "@vben/types",
|
||||||
"path": "packages/types",
|
"path": "packages/types"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"name": "@vben/utils",
|
"name": "@vben/utils",
|
||||||
"path": "packages/utils",
|
"path": "packages/utils"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"name": "@vben/playground",
|
"name": "@vben/playground",
|
||||||
"path": "playground",
|
"path": "playground"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"name": "@vben/turbo-run",
|
"name": "@vben/turbo-run",
|
||||||
"path": "scripts/turbo-run",
|
"path": "scripts/turbo-run"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"name": "@vben/vsh",
|
"name": "@vben/vsh",
|
||||||
"path": "scripts/vsh",
|
"path": "scripts/vsh"
|
||||||
},
|
}
|
||||||
],
|
]
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user