-
Notifications
You must be signed in to change notification settings - Fork 15
Expand file tree
/
Copy pathrollup.config.js
More file actions
67 lines (64 loc) · 2.4 KB
/
rollup.config.js
File metadata and controls
67 lines (64 loc) · 2.4 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
import svelte from "rollup-plugin-svelte";
import resolve from "@rollup/plugin-node-resolve";
import postcss from 'rollup-plugin-postcss';
import typescript from "@rollup/plugin-typescript";
import { sveltePreprocess } from "svelte-preprocess";
import commonjs from "@rollup/plugin-commonjs";
import sass from "@csstools/postcss-sass";
const environment = process.env.ROLLUP_ENV || "production";
export default {
logLevel: "trace",
input: {
main: "./frontend/argus.js",
fontAwesome: "./frontend/font-awesome.js",
globalAlert: "./frontend/Alert.js",
notificationCounter: "./frontend/notification-counter.js",
flashDebug: "./frontend/flashDebug.js",
login: "./frontend/login.js",
workArea: "./frontend/work-area.js",
adminPanel: "./frontend/admin-panel.js",
releasePage: "./frontend/release-page.js",
testRunDetails: "./frontend/test-run-details.js",
testRunsStandalone: "./frontend/test-runs-standalone.js",
runByPlugin: "./frontend/run-by-plugin.js",
testRuns: "./frontend/test-runs-breakout.js",
releaseDashboard: "./frontend/release-dashboard.js",
plan: "./frontend/plan.js",
viewDashboard: "./frontend/view-dashboard.js",
viewUserResolver: "./frontend/view-user-resolver.js",
releaseScheduler: "./frontend/release-scheduler.js",
releasePlanner: "./frontend/release-planner.js",
dutyPlanner: "./frontend/duty-planner.js",
profileJobs: "./frontend/profile-jobs.js",
profileNotifications: "./frontend/profile-notifications.js",
profileSchedules: "./frontend/profile-schedules.js",
teams: "./frontend/teams.js",
},
output: {
sourcemap: environment !== "production",
compact: environment === "production",
dir: "public/dist",
format: "esm",
entryFileNames: "[name].bundle.js",
assetFileNames: "public/dist/assets/[name][extname]",
globals: {
globalAlert: 'sendMessage'
}
},
plugins: [
commonjs(),
postcss({
extract: "styles.css",
plugins: [
sass(),
]
}),
typescript(),
resolve({ browser: true, exportConditions: ['svelte'], }),
svelte({
preprocess: sveltePreprocess(),
include: "/**/*.svelte",
emitCss: true,
}),
]
};