mirror of
https://github.com/uniwhale-io/DefiLlama-yield-server.git
synced 2026-01-12 08:53:45 +08:00
27 lines
617 B
JavaScript
27 lines
617 B
JavaScript
const slsw = require('serverless-webpack');
|
|
const path = require('path');
|
|
|
|
module.exports = {
|
|
entry: slsw.lib.entries,
|
|
target: 'node',
|
|
mode: slsw.lib.webpack.isLocal ? 'development' : 'production',
|
|
module: {
|
|
rules: [
|
|
{
|
|
test: /\.(ts|js)$/,
|
|
use: { loader: 'babel-loader' },
|
|
include: path.resolve(__dirname, 'src'),
|
|
exclude: /node_modules/,
|
|
},
|
|
],
|
|
},
|
|
resolve: {
|
|
mainFields: ['main'],
|
|
extensions: ['.js', '.ts', '.json'],
|
|
alias: {
|
|
'bignumber.js$': 'bignumber.js/bignumber.js',
|
|
'node-fetch$': 'node-fetch/lib/index.js',
|
|
},
|
|
},
|
|
};
|