mirror of
https://github.com/grafana/grafana.git
synced 2025-07-28 21:02:22 +08:00

* feat(grafana-data): introduce unstable entrypoint to package * feat(grafana-runtime): introduce unstable entrypoint to package * feat(plugins): expose unstable entrypoints for data and runtime to plugins * feat(packages): dummy exports so package verification and shared deps imports work
34 lines
759 B
TypeScript
34 lines
759 B
TypeScript
import { createRequire } from 'node:module';
|
|
|
|
import { entryPoint, plugins, esmOutput, cjsOutput, tsDeclarationOutput } from '../rollup.config.parts';
|
|
|
|
const rq = createRequire(import.meta.url);
|
|
const pkg = rq('./package.json');
|
|
|
|
export default [
|
|
{
|
|
input: entryPoint,
|
|
plugins,
|
|
output: [cjsOutput(pkg), esmOutput(pkg, 'grafana-data')],
|
|
},
|
|
{
|
|
input: 'src/unstable.ts',
|
|
plugins,
|
|
output: [cjsOutput(pkg), esmOutput(pkg, 'grafana-data')],
|
|
},
|
|
tsDeclarationOutput(pkg),
|
|
tsDeclarationOutput(pkg, {
|
|
input: './compiled/unstable.d.ts',
|
|
output: [
|
|
{
|
|
file: './dist/cjs/unstable.d.cts',
|
|
format: 'cjs',
|
|
},
|
|
{
|
|
file: './dist/esm/unstable.d.mts',
|
|
format: 'es',
|
|
},
|
|
],
|
|
}),
|
|
];
|