forked from Refinitiv/refinitiv-ui
-
Notifications
You must be signed in to change notification settings - Fork 0
/
server.config.js
35 lines (34 loc) · 914 Bytes
/
server.config.js
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
#!/usr/bin/env node
/**
* Generic configuration for web-server.
* Extend as required
*/
const { legacyPlugin } = require('@web/dev-server-legacy');
const { ROOT } = require('./scripts/helpers');
const path = require('path');
module.exports = {
rootDir: ROOT,
open: true,
watch: false,
nodeResolve: true,
preserveSymlinks: true,
appIndex: '/',
plugins: [
legacyPlugin({
polyfills: {
webcomponents: true,
shadyCssCustomStyle: true,
// Inject lit's polyfill-support module into test files, which is required
// for interfacing with the webcomponents polyfills
custom: [
{
name: 'lit-polyfill-support',
path: path.resolve(ROOT, 'node_modules/lit/polyfill-support.js'),
test: "!('attachShadow' in Element.prototype)",
module: false,
}
]
}
}) // IE11 support
]
};