This repository has been archived on 2024-07-22. You can view files and clone it, but cannot push or open issues or pull requests.
Doric/js-framework/rollup.config.js

44 lines
1022 B
JavaScript
Raw Normal View History

2019-07-17 15:03:31 +08:00
const path = require('path')
const fs = require('fs')
import resolve from 'rollup-plugin-node-resolve'
import commonjs from 'rollup-plugin-commonjs'
export default [
{
input: "build/index.runtime.js",
output: {
2019-07-19 10:27:09 +08:00
name: "doric",
2019-07-17 15:03:31 +08:00
format: "iife",
2019-07-19 10:27:09 +08:00
file: "bundle/doric-sandbox.js",
2019-07-17 15:03:31 +08:00
},
sourceMap: true,
plugins: [
resolve({ jsnext: true, main: true }),
2019-07-18 11:34:43 +08:00
commonjs()
2019-07-17 15:03:31 +08:00
]
},
{
input: "build/index.js",
output: {
format: "cjs",
2019-07-19 10:27:09 +08:00
file: "bundle/doric-lib.js",
2019-07-17 15:03:31 +08:00
},
sourceMap: true,
plugins: [
resolve({ jsnext: true, main: true }),
]
},
2019-07-18 16:29:24 +08:00
{
2019-07-18 16:31:50 +08:00
input: "build/demo.js",
2019-07-18 16:29:24 +08:00
output: {
format: "cjs",
2019-07-18 16:31:50 +08:00
file: "demo/demo.js",
2019-07-18 16:29:24 +08:00
},
sourceMap: true,
plugins: [
resolve({ jsnext: true, main: true }),
commonjs()
],
external: ['./index'],
},
2019-07-17 15:03:31 +08:00
]