@wyw-in-js/nextjs 1.0.9 → 2.0.0-alpha.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +5 -5
- package/esm/index.mjs +265 -349
- package/esm/index.mjs.map +1 -1
- package/package.json +12 -13
- package/types/index.d.ts +2 -1
- package/types/index.js +25 -86
- package/lib/index.js +0 -394
- package/lib/index.js.map +0 -1
package/README.md
CHANGED
|
@@ -23,10 +23,10 @@ bun add -d @wyw-in-js/nextjs
|
|
|
23
23
|
## Usage
|
|
24
24
|
|
|
25
25
|
```js
|
|
26
|
-
// next.config.
|
|
27
|
-
|
|
26
|
+
// next.config.mjs
|
|
27
|
+
import { withWyw } from '@wyw-in-js/nextjs';
|
|
28
28
|
|
|
29
|
-
|
|
29
|
+
export default withWyw({
|
|
30
30
|
// your Next config
|
|
31
31
|
});
|
|
32
32
|
```
|
|
@@ -36,7 +36,7 @@ By default, the plugin:
|
|
|
36
36
|
- injects `@wyw-in-js/webpack-loader` into Next's JS/TS pipeline;
|
|
37
37
|
- emits styles as `*.wyw-in-js.module.css` so imports are allowed from any module;
|
|
38
38
|
- keeps generated class names stable under Next CSS Modules (selectors are emitted as `:global(...)`).
|
|
39
|
-
-
|
|
39
|
+
- parses and evaluates JS/TS/JSX/TSX through the Oxc-backed WyW transform.
|
|
40
40
|
|
|
41
41
|
## Options
|
|
42
42
|
|
|
@@ -47,6 +47,6 @@ import type { WywNextPluginOptions } from '@wyw-in-js/nextjs';
|
|
|
47
47
|
Use `loaderOptions` to pass options through to `@wyw-in-js/webpack-loader`.
|
|
48
48
|
|
|
49
49
|
Use `turbopackLoaderOptions` to pass JSON-serializable options to `@wyw-in-js/turbopack-loader` (use `configFile` for
|
|
50
|
-
function-based config).
|
|
50
|
+
function/RegExp-based config).
|
|
51
51
|
|
|
52
52
|
To disable vendor prefixing (Stylis prefixer), set `prefixer: false` in `loaderOptions` and/or `turbopackLoaderOptions`.
|