Skip to content

Commit 205f946

Browse files
author
Denis Bardadym
committed
Update readme for rolldown
1 parent e76cde2 commit 205f946

File tree

1 file changed

+29
-15
lines changed

1 file changed

+29
-15
lines changed

README.md

Lines changed: 29 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -43,6 +43,18 @@ module.exports = {
4343
};
4444
```
4545

46+
Usage with rolldown (rolldown.config.ts)
47+
48+
```js
49+
import { defineConfig, type RolldownPlugin } from 'rolldown';
50+
51+
export default defineConfig({
52+
plugins: [
53+
visualizer() as RolldownPlugin
54+
],
55+
})
56+
```
57+
4658
Usage with vite (vite.config.js)
4759

4860
```js
@@ -54,10 +66,11 @@ module.exports = {
5466
Usage with vite TypeScript (vite.config.ts)
5567

5668
```ts
57-
import { defineConfig, type PluginOption } from 'vite'
69+
import { defineConfig, type PluginOption } from "vite";
70+
5871
export default defineConfig({
5972
plugins: [visualizer() as PluginOption],
60-
})
73+
});
6174
```
6275

6376
Usage with SvelteKit (vite.config.js)
@@ -145,14 +158,15 @@ Output yml file with all the data, could be good idea to commit this file to tra
145158
#### Include and Exclude
146159

147160
Include and exclude filters uses glob matchers with picomatch. In UI you can do such combinations (both exclude and include):
148-
* Filter bundle and file in one string
149-
* `translation-*.js:*/**/index.js` - this selects all bundles that matches `translation-*.js` and all the files by all paths that name is `index.js`. `:` is separator and required only when bundle search used.
150-
* Format for this kind of filter is `BUNDLE_GLOB:FILE_GLOB`
151-
* Filter bundle in one string
152-
* This is special case of bundle+file filter, you need to omit `FILE_GLOB` part (empty string)
153-
* Filter file in one string
154-
* **This is DEFAULT search option**
155-
* `*/**/index.js` - select all files that name is index.js
161+
162+
- Filter bundle and file in one string
163+
- `translation-*.js:*/**/index.js` - this selects all bundles that matches `translation-*.js` and all the files by all paths that name is `index.js`. `:` is separator and required only when bundle search used.
164+
- Format for this kind of filter is `BUNDLE_GLOB:FILE_GLOB`
165+
- Filter bundle in one string
166+
- This is special case of bundle+file filter, you need to omit `FILE_GLOB` part (empty string)
167+
- Filter file in one string
168+
- **This is DEFAULT search option**
169+
- `*/**/index.js` - select all files that name is index.js
156170

157171
## CLI
158172

@@ -189,8 +203,8 @@ See CHANGELOG.md.
189203

190204
## Versioning
191205

192-
* Plugin backend (one appears in configs) are strictly follows SemVer
193-
* Plugin frontend (generated file):
194-
* `network`, `treemap`, `sunburst` can change does not matter of version (colors, texts, visual structure etc)
195-
* `raw-data` format follows own `version` property
196-
* `list` follows semver
206+
- Plugin backend (one appears in configs) are strictly follows SemVer
207+
- Plugin frontend (generated file):
208+
- `network`, `treemap`, `sunburst` can change does not matter of version (colors, texts, visual structure etc)
209+
- `raw-data` format follows own `version` property
210+
- `list` follows semver

0 commit comments

Comments
 (0)