PromucFlow_constructor/app/shared/ast/rollup.config.js
Ayangade Adeoluwa 3de00c6bf4
feat: Extraction of AST Logic (#15892)
* POC for Shared AST Logic using Yarn Symlinks

* fix: preinstall script for bundling shared packages

* Merge commit

* fix: updated the script to link, unlink the package as shared dep

* fix: updated dependencies

* Add a post-install script and fix yarn.lock file

* Remove commented code

* fix: added verification script, readme, moved scripts to shared

* Extraction of AST Logic into shared/ast folder

* Add jest test script

* Replace hardcoded ast Logic use with Shared AST module

* Replace parse code with getAST

Co-authored-by: Aman Agarwal <aman@appsmith.com>
2022-08-23 16:39:42 +05:30

32 lines
812 B
JavaScript

import peerDepsExternal from "rollup-plugin-peer-deps-external";
import commonjs from "@rollup/plugin-commonjs";
import typescript from "rollup-plugin-typescript2";
import generatePackageJson from "rollup-plugin-generate-package-json";
const packageJson = require("./package.json");
export default {
// TODO: Figure out regex where each directory can be a separate module without having to manually add them
input: ["./index.ts"],
output: [
{
file: packageJson.module,
format: "esm",
sourcemap: true,
},
{
file: packageJson.main,
format: "cjs",
sourcemap: true,
},
],
plugins: [
peerDepsExternal(),
commonjs(),
typescript({ useTsconfigDeclarationDir: true }),
generatePackageJson({
baseContents: (pkg) => pkg,
}),
],
};