1 | "use strict";
|
2 | Object.defineProperty(exports, "__esModule", { value: true });
|
3 | const runner_utils_1 = require("@tarojs/runner-utils");
|
4 | const Chain = require("webpack-chain");
|
5 | exports.default = (_appPath, _config) => {
|
6 | const chain = new Chain();
|
7 | chain.merge({
|
8 | resolve: {
|
9 | extensions: ['.mjs', '.js', '.jsx', '.ts', '.tsx', '.vue'],
|
10 | mainFields: ['main:h5', 'browser', 'module', 'jsnext:main', 'main'],
|
11 | symlinks: true,
|
12 | alias: {
|
13 |
|
14 | '@tarojs/runtime': require.resolve('@tarojs/runtime'),
|
15 | '@tarojs/shared': require.resolve('@tarojs/shared/dist/shared.esm.js')
|
16 | }
|
17 | },
|
18 | resolveLoader: {
|
19 | modules: ['node_modules']
|
20 | }
|
21 | });
|
22 | chain.resolve
|
23 | .plugin('MultiPlatformPlugin')
|
24 | .use(runner_utils_1.MultiPlatformPlugin, ['described-resolve', 'resolve', {
|
25 | chain
|
26 | }]);
|
27 | return chain;
|
28 | };
|
29 |
|
\ | No newline at end of file |