g6/packages/g6-extension-3d/rollup.config.mjs
Aaron da5297cd8c
feat: add 3d elements, plugin (#5597)
* refactor: adjust exports, use enum replace const enum

* fix: fix issue that unexpected z attr

* feat(utils): add TupleMap and getCacheKey

* feat(elements): add 3d elements

* feat(plugins): add 3d light

* refactor: adjust 3d renderer

* refactor: adjust exports

* test: add demos

* chore: config packages.json, jest config

* test: fix test case

* chore: update g6-extension-3d version

* chore: setup project configs

* test: fix demo type issue

* chore: config tsconfig for type-check
2024-03-29 11:57:10 +08:00

31 lines
763 B
JavaScript

import commonjs from '@rollup/plugin-commonjs';
import resolve from '@rollup/plugin-node-resolve';
import terser from '@rollup/plugin-terser';
import typescript from '@rollup/plugin-typescript';
import nodePolyfills from 'rollup-plugin-polyfill-node';
import { visualizer } from 'rollup-plugin-visualizer';
const isBundleVis = !!process.env.BUNDLE_VIS;
export default [
{
input: 'src/index.ts',
output: {
file: 'dist/g6-extension-3d.min.js',
name: 'g6-extension-3d',
format: 'umd',
sourcemap: false,
},
plugins: [
nodePolyfills(),
resolve(),
commonjs(),
typescript({
tsconfig: 'tsconfig.build.json',
}),
terser(),
...(isBundleVis ? [visualizer()] : []),
],
},
];