This repository has been archived by the owner on Mar 23, 2023. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 3
/
nwb.config.js
77 lines (77 loc) · 3.09 KB
/
nwb.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
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
module.exports = {
type: 'react-component',
browsers: '>0.01%',
npm: {
umd: {
global: 'NAVChatBot',
externals: {
react: 'React',
'@navikt/fnrvalidator': '@navikt/fnrvalidator',
'nav-frontend-chevron-style': 'nav-frontend-chevron-style',
'nav-frontend-core': 'nav-frontend-core',
'nav-frontend-ikoner-assets': 'nav-frontend-ikoner-assets',
'nav-frontend-js-utils': 'nav-frontend-js-utils',
'nav-frontend-knapper': 'nav-frontend-knapper',
'nav-frontend-knapper-style': 'nav-frontend-knapper-style',
'nav-frontend-lenkepanel': 'nav-frontend-lenkepanel',
'nav-frontend-lenkepanel-style':
'nav-frontend-lenkepanel-style',
'nav-frontend-lenker': 'nav-frontend-lenker',
'nav-frontend-lenker-style': 'nav-frontend-lenker-style',
'nav-frontend-paneler': 'nav-frontend-paneler',
'nav-frontend-paneler-style': 'nav-frontend-paneler-style',
'nav-frontend-skjema': 'nav-frontend-skjema',
'nav-frontend-skjema-style': 'nav-frontend-skjema-style',
'nav-frontend-spinner': 'nav-frontend-spinner',
'nav-frontend-spinner-style': 'nav-frontend-spinner-style',
'nav-frontend-typografi': 'nav-frontend-typografi',
'nav-frontend-typografi-style': 'nav-frontend-typografi-style',
'styled-components': 'styled-components'
}
},
cjs: false,
esModules: false
},
webpack: {
extra: {
entry: './src/index',
resolve: {
extensions: ['.ts', '.tsx', '.js', '.jsx', '.less']
},
module: {
rules: [
{
test: /\.ts|\.tsx$/,
use: [
{
loader: 'babel-loader',
options: {
plugins: [
[
'@quickbaseoss/babel-plugin-styled-components-css-namespace',
{
cssNamespace: '#nav-chatbot'
}
],
'babel-plugin-styled-components'
]
}
},
'ts-loader'
]
},
{
test: /\.less$/,
use: ['style-loader', 'css-loader', 'less-loader']
}
]
}
},
rules: {
svg: {
loader: 'svg-inline-loader'
}
},
copy: [{from: './src/index.d.ts', to: './'}]
}
};