Permalink
Cannot retrieve contributors at this time
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
33 lines (32 sloc)
815 Bytes
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| import babel from "@rollup/plugin-babel"; | |
| import commonjs from "@rollup/plugin-commonjs"; | |
| import replace from "@rollup/plugin-replace"; | |
| import resolve from "@rollup/plugin-node-resolve"; | |
| import typescript from "@rollup/plugin-typescript"; | |
| import json from "@rollup/plugin-json"; | |
| import css from "rollup-plugin-import-css"; | |
| import { env } from "process"; | |
| export default { | |
| input: "src/index.ts", | |
| output: { | |
| format: "cjs", | |
| file: "main.js", | |
| exports: "default", | |
| }, | |
| external: ["obsidian", "fs", "os", "path"], | |
| plugins: [ | |
| typescript(), | |
| resolve({ | |
| browser: true, | |
| }), | |
| replace({ | |
| "process.env.NODE_ENV": JSON.stringify(env.NODE_ENV), | |
| }), | |
| babel({ | |
| presets: ["@babel/preset-react", "@babel/preset-typescript"], | |
| }), | |
| commonjs(), | |
| json(), | |
| css(), | |
| ], | |
| }; |