-
Notifications
You must be signed in to change notification settings - Fork 1
/
ember-cli-build.js
81 lines (74 loc) · 1.88 KB
/
ember-cli-build.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
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
68
69
70
71
72
73
74
75
76
77
78
79
80
81
'use strict';
const EmberApp = require('ember-cli/lib/broccoli/ember-app');
module.exports = async function (defaults) {
const { setConfig } = await import('@warp-drive/build-config');
process.on('uncaughtException', (err) => {
console.error(err.stack);
});
let app = new EmberApp(defaults, {
'ember-simple-auth': {
useSessionSetupMethod: true,
},
'ember-cli-babel': {
enableTypeScriptTransform: true
},
babel: {
sourceMaps: 'inline',
plugins: [require.resolve("ember-concurrency/async-arrow-task-transform"), ...require('ember-cli-code-coverage').buildBabelPlugin({ embroider: true })],
},
'@embroider/macros': {
setConfig: {
'@ember-data/store': {
polyfillUUID: true,
},
},
},
'ember-fetch': {
nativePromise: true
},
sourcemaps: {
enabled: true,
extensions: ['js'],
},
postcssOptions: {
compile: {
enabled: true,
includePaths: ['app'],
plugins: [
{
module: require('postcss-import'),
options: {
path: ['node_modules'],
},
},
require('tailwindcss')('tailwind.config.js'),
],
cacheInclude: [/.*\.(css|hbs|html|gts|gjs|ts)$/, /tailwind\.config\.js/],
},
},
});
const { Webpack } = require('@embroider/webpack');
setConfig(app, __dirname, {
compatWith: '99.0',
});
return require('@embroider/compat').compatBuild(app, Webpack, {
packagerOptions: {
webpackConfig: {
devtool: 'source-map',
},
},
skipBabel: [
{
package: 'qunit',
},
],
staticAddonTrees: true,
staticAddonTestSupportTrees: true,
staticHelpers: true,
staticModifiers: true,
staticComponents: true,
splitControllers: true,
splitRouteClasses: true,
staticEmberSource: true
});
};