antv-l7/gatsby-node.js

17 lines
455 B
JavaScript
Raw Normal View History

2019-11-14 22:24:31 +08:00
const path = require('path');
2019-11-20 20:44:08 +08:00
exports.onCreateWebpackConfig = ({ getConfig }) => {
2019-11-14 18:15:58 +08:00
const config = getConfig();
config.module.rules.push({
test: /\.glsl$/,
use: {
loader: 'glsl-shaders-loader'
}
});
2019-11-14 18:15:58 +08:00
config.resolve.extensions.push('.glsl');
2019-11-14 22:24:31 +08:00
config.resolve.alias = {
...config.resolve.alias,
'@antv/l7': path.resolve(__dirname, 'packages/l7/src'),
'@antv/l7-maps': path.resolve(__dirname, 'packages/maps/src')
2019-11-14 22:24:31 +08:00
};
2019-11-14 18:15:58 +08:00
};