Skip to content

Commit 3e013f5

Browse files
author
Joel Denning
authored
Add deprecation notice (#20)
* Add deprecation notice * Update README.md
1 parent 9c183e4 commit 3e013f5

File tree

1 file changed

+5
-1
lines changed

1 file changed

+5
-1
lines changed

README.md

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,10 @@
22

33
A configurable NodeJS loader that combines multiple other loaders into one.
44

5+
## Deprecation Notice
6+
7+
As of NodeJS 20, combining multiple loaders into one loader is possible via [chaining with the `--import` flag](https://nodejs.org/docs/latest-v20.x/api/module.html#chaining). It is recommended to switch to native NodeJS chaining.
8+
59
## Motivation
610

711
[NodeJS Loaders](https://nodejs.org/dist/latest-v14.x/docs/api/esm.html#esm_experimental_loaders) are a new feature that allow you to configure the behavior of modules loaded with `import` or `import()`. NodeJS currently only allows you to specify a single loader when starting up Node. However, the `@node-loader/core` project allows you to combine multiple into a single loader through a configuration file.
@@ -12,7 +16,7 @@ A configurable NodeJS loader that combines multiple other loaders into one.
1216
npm install --save @node-loader/core
1317
```
1418

15-
For NodeJS@<16.12, use `@node-loader/core@1`. For NodeJS@>=16.12, use `@node-loader/core@latest`.
19+
For NodeJS@<16.12, use `@node-loader/core@1`. For NodeJS@>=16.12 but <20, use `@node-loader/core@latest`. For Node >=20, use [`--import` chaining](https://nodejs.org/docs/latest-v20.x/api/module.html#chaining)
1620

1721
## Usage
1822

0 commit comments

Comments
 (0)