https://github.com/cgqaq/rollup-plugin-dbg
Rust dbg! in js powered by rollup/vite plugin system
https://github.com/cgqaq/rollup-plugin-dbg
debug rollup-plugin vite-plugin
Last synced: 10 months ago
JSON representation
Rust dbg! in js powered by rollup/vite plugin system
- Host: GitHub
- URL: https://github.com/cgqaq/rollup-plugin-dbg
- Owner: CGQAQ
- License: mit
- Created: 2022-08-12T10:00:07.000Z (almost 4 years ago)
- Default Branch: main
- Last Pushed: 2022-08-18T03:42:12.000Z (almost 4 years ago)
- Last Synced: 2025-08-16T00:48:40.026Z (11 months ago)
- Topics: debug, rollup-plugin, vite-plugin
- Language: JavaScript
- Homepage: https://www.npmjs.com/package/rollup-plugin-dbg
- Size: 43 KB
- Stars: 17
- Watchers: 1
- Forks: 1
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# rollup-plugin-dbg
## This plugin is also compatible with vite
### use with rollup
```js
import { defineConfig } from "rollup";
import config from "./package.json";
import PluginDbg from "rollup-plugin-dbg";
export default defineConfig({
plugins: [PluginDbg({ projectRoot: __dirname })],
input: "./index.js",
output: [
{
file: config.exports["."].import,
format: "es",
},
{
file: config.exports["."].require,
format: "commonjs",
exports: "auto",
},
],
});
```
### use with vite
```js
import { defineConfig } from "vite";
import PluginDbg from "rollup-plugin-dbg";
export default defineConfig({
mode: "development",
plugins: [PluginDbg()], // do not need projectRoot when using with vite
build: {
outDir: "dist",
lib: {
entry: "index.js",
name: "example",
},
},
});
```