Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 1 addition & 4 deletions packages/rspack/etc/core.api.md
Original file line number Diff line number Diff line change
Expand Up @@ -667,7 +667,7 @@ interface CallExpression extends ExpressionBase {
type CallFn = (...args: any[]) => any;

// @public (undocumented)
const CaseSensitivePlugin: {
export const CaseSensitivePlugin: {
new (): {
name: string;
_args: [];
Expand All @@ -676,8 +676,6 @@ const CaseSensitivePlugin: {
apply(compiler: Compiler): void;
};
};
export { CaseSensitivePlugin }
export { CaseSensitivePlugin as WarnCaseSensitiveModulesPlugin }

// @public (undocumented)
interface CatchClause extends Node_4, HasSpan {
Expand Down Expand Up @@ -6579,7 +6577,6 @@ declare namespace rspackExports {
ProvidePluginOptions,
BannerPlugin,
CaseSensitivePlugin,
CaseSensitivePlugin as WarnCaseSensitiveModulesPlugin,
DefinePlugin,
DynamicEntryPlugin,
EntryPlugin,
Expand Down
1 change: 0 additions & 1 deletion packages/rspack/scripts/check-documentation-coverage.ts
Original file line number Diff line number Diff line change
Expand Up @@ -112,7 +112,6 @@ function checkPluginsDocumentationCoverage() {
'RsdoctorPlugin', // This plugin is not stable yet
'RstestPlugin', // This plugin is not stable yet
'RslibPlugin', // This plugin is not stable yet
'WarnCaseSensitiveModulesPlugin', // This plugin is deprecated and will be replaced with CaseSensitivePlugin
];

const undocumentedPlugins = Array.from(implementedPlugins).filter(
Expand Down
4 changes: 0 additions & 4 deletions packages/rspack/src/exports.ts
Original file line number Diff line number Diff line change
Expand Up @@ -106,10 +106,6 @@ export type {
export {
BannerPlugin,
CaseSensitivePlugin,
/**
* @deprecated Use `rspack.CaseSensitivePlugin` instead
*/
CaseSensitivePlugin as WarnCaseSensitiveModulesPlugin,
DefinePlugin,
DynamicEntryPlugin,
EntryPlugin,
Expand Down
4 changes: 2 additions & 2 deletions tests/rspack-test/errorCases/error-case-sensitive.js
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
const fs = require("fs");
const path = require("path");
const { WarnCaseSensitiveModulesPlugin } = require("@rspack/core");
const { CaseSensitivePlugin } = require("@rspack/core");

const isCaseInsensitiveFilesystem = fs.existsSync(
path.resolve(__dirname, "../fixtures", "errors", "FILE.js")
Expand All @@ -13,7 +13,7 @@ module.exports = isCaseInsensitiveFilesystem
return {
mode: "development",
entry: "./case-sensitive",
plugins: [new WarnCaseSensitiveModulesPlugin()]
plugins: [new CaseSensitivePlugin()]
};
},
async check(diagnostics) {
Expand Down
4 changes: 0 additions & 4 deletions website/docs/en/plugins/webpack/case-sensitive-plugin.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -4,10 +4,6 @@ import { ApiMeta } from '@components/ApiMeta.tsx';

<ApiMeta addedVersion={'1.2.0'} />

:::tip
This plugin was renamed to `CaseSensitivePlugin` in v1.7.0. `WarnCaseSensitiveModulesPlugin` is deprecated and will be removed in a future release.
:::

Detect case sensitivity conflicts in referenced module names and emit warnings.

Different operating systems may handle case sensitivity in file systems differently. When code references module names that differ only in case, this can lead to unexpected errors during cross-platform compilation. This plugin helps to avoid such situations.
Expand Down
4 changes: 0 additions & 4 deletions website/docs/zh/plugins/webpack/case-sensitive-plugin.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -4,10 +4,6 @@ import { ApiMeta } from '@components/ApiMeta.tsx';

<ApiMeta addedVersion={'1.2.0'} />

:::tip
该插件在 v1.7.0 中更名为 `CaseSensitivePlugin`。`WarnCaseSensitiveModulesPlugin` 已被废弃,并将在未来的版本中移除。
:::

检测引用的模块名称的大小写冲突,并发出警告。

在不同操作系统中,文件系统对大小写的处理方式可能不同。当代码中引用仅大小写不同的模块名称时,可能会导致跨系统编译时出现意外的错误,这个插件用于预防这种情况。
Expand Down
Loading