Skip to content

Commit

Permalink
fix(plugin-chart-handlebars): Update webpack/babel config to fix buil…
Browse files Browse the repository at this point in the history
…d/runtime warnings/errors (apache#21779)

(cherry picked from commit d5b4bde)
  • Loading branch information
codyml authored and sadpandajoe committed Oct 14, 2022
1 parent bd3166b commit 7b72fdf
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 0 deletions.
6 changes: 6 additions & 0 deletions superset-frontend/babel.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -103,4 +103,10 @@ module.exports = {
plugins: [],
},
},
overrides: [
{
test: './plugins/plugin-chart-handlebars/node_modules/just-handlebars-helpers/*',
sourceType: 'unambiguous',
},
],
};
3 changes: 3 additions & 0 deletions superset-frontend/webpack.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -289,6 +289,9 @@ const config = {
// AntD version conflict has been resolved
antd: path.resolve(path.join(APP_DIR, './node_modules/antd')),
react: path.resolve(path.join(APP_DIR, './node_modules/react')),
// TODO: remove Handlebars alias once Handlebars NPM package has been updated to
// correctly support webpack import (https://github.com/handlebars-lang/handlebars.js/issues/953)
handlebars: 'handlebars/dist/handlebars.js',
},
extensions: ['.ts', '.tsx', '.js', '.jsx', '.yml'],
fallback: {
Expand Down

0 comments on commit 7b72fdf

Please sign in to comment.